Changeset 989 for trunk/dll/avv.c


Ignore:
Timestamp:
Mar 2, 2008, 12:34:12 AM (18 years ago)
Author:
Gregg Young
Message:

Refactor fm3dll.h to create command.h; broken ini is now replaced with backup or new ini as available; more variable command line ledth changes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dll/avv.c

    r985 r989  
    9595{ // fixme for command line limit
    9696  CHAR *szCmdLine;
     97  PSZ pszWorkBuf;
    9798
    9899  szCmdLine = xmalloc(MaxComLineStrg, pszSrcFile, __LINE__);
    99         if (!szCmdLine)
    100           return NULL; //already complained
    101   xfree(pszDest);
    102   WinQueryDlgItemText(hwnd, id, sizeof(szCmdLine), szCmdLine);
    103   if (*szCmdLine){
    104     PSZ pszWorkBuf;
     100  if (szCmdLine) {
     101    xfree(pszDest);
     102    WinQueryDlgItemText(hwnd, id, sizeof(szCmdLine), szCmdLine);
    105103    pszWorkBuf = xmalloc(MaxComLineStrg, pszSrcFile, __LINE__);
    106104    if (pszWorkBuf) {
     
    111109    else
    112110      pszDest = xstrdup(szCmdLine, pszSrcFile, __LINE__); // return the unexamined input on failure
     111    xfree(szCmdLine);
    113112  }
    114113  else
    115114    pszDest = NULL;
    116   xfree(szCmdLine);
    117115  return pszDest;
    118116}
Note: See TracChangeset for help on using the changeset viewer.