Changeset 920 for trunk/dll/assoc.c


Ignore:
Timestamp:
Jan 13, 2008, 2:18:17 AM (18 years ago)
Author:
Gregg Young
Message:

Cleanup of NormalizeCmdLine moved to pathutil.c

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dll/assoc.c

    r918 r920  
    1515  19 Apr 07 SHL Sync with AcceptOneDrop GetOneDrop mods
    1616  20 Aug 07 GKY Move #pragma alloc_text to end for OpenWatcom compat
    17   06 Jan 08 GKY Use CheckApp_QuoteAddExe to check program strings on entry
     17  06 Jan 08 GKY Use NormalizeCmdLine to check program strings on entry
    1818
    1919**************************************************************************************/
     
    632632        ASSOC temp;
    633633        CHAR dummy[34];
    634         PSZ psz;
     634        PSZ pszWorkBuf;
    635635        replace = FALSE;
    636636
     
    645645                                          MPFROMSHORT(0), MPFROMSHORT(TRUE));
    646646        }
    647         psz = xmalloc(MAXCOMLINESTRG, pszSrcFile, __LINE__);
     647        pszWorkBuf = xmalloc(MAXCOMLINESTRG, pszSrcFile, __LINE__);
    648648        memset(&temp, 0, sizeof(ASSOC));
    649649        WinQueryDlgItemText(hwnd, ASS_MASK, sizeof(temp.mask), temp.mask);
    650650        WinQueryDlgItemText(hwnd, ASS_CL, sizeof(temp.cl), temp.cl);
    651         CheckApp_QuoteAddExe(psz, temp.cl);
    652         memcpy(temp.cl, psz, strlen(psz) + 1);
     651        NormalizeCmdLine(pszWorkBuf, temp.cl);
     652        memcpy(temp.cl, pszWorkBuf, strlen(pszWorkBuf) + 1);
    653653        WinQueryDlgItemText(hwnd, ASS_SIG, sizeof(temp.sig), temp.sig);
    654654        rstrip(temp.sig);
     
    730730        ASSOC temp;
    731731        CHAR dummy[34];
    732         PSZ psz;
     732        PSZ pszWorkBuf;
    733733        replace = FALSE;
    734734
    735         psz = xmalloc(MAXCOMLINESTRG, pszSrcFile, __LINE__);
     735        pszWorkBuf = xmalloc(MAXCOMLINESTRG, pszSrcFile, __LINE__);
    736736        memset(&temp, 0, sizeof(ASSOC));
    737737        WinQueryDlgItemText(hwnd, ASS_MASK, sizeof(temp.mask), temp.mask);
    738738        WinQueryDlgItemText(hwnd, ASS_CL, sizeof(temp.cl), temp.cl);
    739         CheckApp_QuoteAddExe(psz, temp.cl);
    740         memcpy(temp.cl, psz, strlen(psz) + 1);
     739        NormalizeCmdLine(pszWorkBuf, temp.cl);
     740        memcpy(temp.cl, pszWorkBuf, strlen(pszWorkBuf) + 1);
    741741        WinQueryDlgItemText(hwnd, ASS_SIG, sizeof(temp.sig), temp.sig);
    742742        rstrip(temp.sig);
     
    840840        ASSOC temp;
    841841        CHAR dummy[34];
    842         PSZ psz;
     842        PSZ pszWorkBuf;
    843843        replace = TRUE;
    844844
     
    847847                                      LM_QUERYSELECTION,
    848848                                      MPFROMSHORT(LIT_CURSOR), MPVOID);
    849         psz = xmalloc(MAXCOMLINESTRG, pszSrcFile, __LINE__);
     849        pszWorkBuf = xmalloc(MAXCOMLINESTRG, pszSrcFile, __LINE__);
    850850        memset(&temp, 0, sizeof(ASSOC));
    851851        WinQueryDlgItemText(hwnd, ASS_MASK, sizeof(temp.mask), temp.mask);
    852852        WinQueryDlgItemText(hwnd, ASS_CL, sizeof(temp.cl), temp.cl);
    853         CheckApp_QuoteAddExe(psz, temp.cl);
    854         memcpy(temp.cl, psz, strlen(psz) + 1);
     853        NormalizeCmdLine(pszWorkBuf, temp.cl);
     854        memcpy(temp.cl, pszWorkBuf, strlen(pszWorkBuf) + 1);
    855855        WinQueryDlgItemText(hwnd, ASS_SIG, sizeof(temp.sig), temp.sig);
    856856        rstrip(temp.sig);
Note: See TracChangeset for help on using the changeset viewer.