filter can be null
This commit is contained in:
parent
45018e6979
commit
dd427253cc
|
@ -213,7 +213,7 @@ FcScandir (const char *dirp,
|
|||
*dlist = NULL;
|
||||
while ((dent = readdir (d)))
|
||||
{
|
||||
if ((filter) (dent))
|
||||
if (!filter || (filter) (dent))
|
||||
{
|
||||
p = (struct dirent *) malloc (sizeof (struct dirent));
|
||||
memcpy (p, dent, sizeof (struct dirent));
|
||||
|
|
Loading…
Reference in New Issue