Changeset 2828 for trunk/kLdr/kLdrHlp.c


Ignore:
Timestamp:
Oct 22, 2006, 8:21:04 PM (19 years ago)
Author:
bird
Message:

Lx header. renaming some helpers.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/kLdr/kLdrHlp.c

    r2826 r2828  
    6161    if (!rc)
    6262    {
    63         size_t cch = strlen(pszValue);
     63        size_t cch = kLdrHlpStrLen(pszValue);
    6464        if (pszVal)
    6565        {
    6666            if (*pcchVal > cch)
    6767            {
    68                 memcpy(pszVal, pszValue, cch + 1);
     68                kLdrHlpMemCopy(pszVal, pszValue, cch + 1);
    6969                *pcchVal = cch;
    7070            }
    7171            else if (*pcchVal)
    7272            {
    73                 memcpy(pszVal, pszValue, *pcchVal);
     73                kLdrHlpMemCopy(pszVal, pszValue, *pcchVal);
    7474                pszVal[*pcchVal - 1] = '\0';
    7575                rc = ERROR_BUFFER_OVERFLOW;
     
    167167
    168168    DosWrite((HFILE)2, s_szMsg1, sizeof(s_szMsg1) - 1, &cbWritten);
    169     DosWrite((HFILE)2, pszExpr, kLdrStrLen(pszExpr), &cbWritten);
     169    DosWrite((HFILE)2, pszExpr, kLdrHlpStrLen(pszExpr), &cbWritten);
    170170    DosWrite((HFILE)2, s_szMsg2, sizeof(s_szMsg2) - 1, &cbWritten);
    171     DosWrite((HFILE)2, pszFile, kLdrStrLen(pszFile), &cbWritten);
     171    DosWrite((HFILE)2, pszFile, kLdrHlpStrLen(pszFile), &cbWritten);
    172172    DosWrite((HFILE)2, "(", sizeof("(") - 1, &cbWritten);
    173173    int2dec(szLine, iLine);
    174     DosWrite((HFILE)2, szLine, kLdrStrLen(szLine), &cbWritten);
     174    DosWrite((HFILE)2, szLine, kLdrHlpStrLen(szLine), &cbWritten);
    175175    DosWrite((HFILE)2, ") ", sizeof(") ") - 1, &cbWritten);
    176     DosWrite((HFILE)2, pszFunction, kLdrStrLen(pszFunction), &cbWritten);
     176    DosWrite((HFILE)2, pszFunction, kLdrHlpStrLen(pszFunction), &cbWritten);
    177177    DosWrite((HFILE)2, s_szMsg3, sizeof(s_szMsg3) - 1, &cbWritten);
    178178
     
    186186
    187187    WriteFile(hStdErr, s_szMsg1, sizeof(s_szMsg1) - 1, &cbWritten, NULL);
    188     WriteFile(hStdErr, pszExpr, kLdrStrLen(pszExpr), &cbWritten, NULL);
     188    WriteFile(hStdErr, pszExpr, kLdrHlpStrLen(pszExpr), &cbWritten, NULL);
    189189    WriteFile(hStdErr, s_szMsg2, sizeof(s_szMsg2) - 1, &cbWritten, NULL);
    190     WriteFile(hStdErr, pszFile, kLdrStrLen(pszFile), &cbWritten, NULL);
     190    WriteFile(hStdErr, pszFile, kLdrHlpStrLen(pszFile), &cbWritten, NULL);
    191191    WriteFile(hStdErr, "(", sizeof("(") - 1, &cbWritten, NULL);
    192192    int2dec(szLine, iLine);
    193     WriteFile(hStdErr, szLine, kLdrStrLen(szLine), &cbWritten, NULL);
     193    WriteFile(hStdErr, szLine, kLdrHlpStrLen(szLine), &cbWritten, NULL);
    194194    WriteFile(hStdErr, ") ", sizeof(") ") - 1, &cbWritten, NULL);
    195     WriteFile(hStdErr, pszFunction, kLdrStrLen(pszFunction), &cbWritten, NULL);
     195    WriteFile(hStdErr, pszFunction, kLdrHlpStrLen(pszFunction), &cbWritten, NULL);
    196196    WriteFile(hStdErr, s_szMsg3, sizeof(s_szMsg3) - 1, &cbWritten, NULL);
    197197
Note: See TracChangeset for help on using the changeset viewer.