Lines Matching refs:dirent
53 PHPAPI int php_alphasort(const struct dirent **a, const struct dirent **b) in php_alphasort()
60 …name, struct dirent **namelist[], int (*selector) (const struct dirent *entry), int (*compare) (co… in php_scandir()
63 struct dirent **vector = NULL; in php_scandir()
66 char entry[sizeof(struct dirent)+MAXPATHLEN]; in php_scandir()
67 struct dirent *dp = (struct dirent *)&entry; in php_scandir()
77 while (!php_readdir_r(dirp, (struct dirent *)entry, &dp) && dp) { in php_scandir()
79 struct dirent *newdp = NULL; in php_scandir()
86 struct dirent **newv; in php_scandir()
93 newv = (struct dirent **) realloc (vector, vector_size * sizeof (struct dirent *)); in php_scandir()
100 dsize = sizeof (struct dirent) + ((strlen(dp->d_name) + 1) * sizeof(char)); in php_scandir()
101 newdp = (struct dirent *) malloc(dsize); in php_scandir()
107 vector[nfiles++] = (struct dirent *) memcpy(newdp, dp, dsize); in php_scandir()
115 qsort (*namelist, nfiles, sizeof(struct dirent *), compare); in php_scandir()