Changeset 565 for trunk/src/sh_files.c


Ignore:
Timestamp:
Jul 1, 2021, 8:48:03 AM (3 years ago)
Author:
katerina
Message:

Fix for ticket #454 (memory leak introduced in version 4.4.4).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/sh_files.c

    r564 r565  
    23232323            }
    23242324          dirlist = addto_sh_dirlist (thisEntry, dirlist);
     2325#if defined(SH_USE_SCANDIR)
     2326          free(entryList[entry]); /* scandir() mallocs entries */
     2327#endif
    23252328        }
    23262329  }
    2327 #if !defined(SH_USE_SCANDIR) 
     2330#if defined(SH_USE_SCANDIR)
     2331  free(entryList);
     2332#else
    23282333  while (thisEntry != NULL);
    23292334#endif
Note: See TracChangeset for help on using the changeset viewer.