Lines Matching refs:bufStart
390 UTIL_STATIC int UTIL_prepareFileList(const char *dirName, char** bufStart, size_t* pos, char** bufE… in UTIL_prepareFileList() argument
426 …nbFiles += UTIL_prepareFileList(path, bufStart, pos, bufEnd); /* Recursively call "UTIL_prepareFi… in UTIL_prepareFileList()
427 if (*bufStart == NULL) { free(path); FindClose(hFile); return 0; } in UTIL_prepareFileList()
430 if (*bufStart + *pos + pathLength >= *bufEnd) { in UTIL_prepareFileList()
431 ptrdiff_t newListSize = (*bufEnd - *bufStart) + LIST_SIZE_INCREASE; in UTIL_prepareFileList()
432 *bufStart = (char*)UTIL_realloc(*bufStart, newListSize); in UTIL_prepareFileList()
433 *bufEnd = *bufStart + newListSize; in UTIL_prepareFileList()
434 if (*bufStart == NULL) { free(path); FindClose(hFile); return 0; } in UTIL_prepareFileList()
436 if (*bufStart + *pos + pathLength < *bufEnd) { in UTIL_prepareFileList()
437 strncpy(*bufStart + *pos, path, *bufEnd - (*bufStart + *pos)); in UTIL_prepareFileList()
454 UTIL_STATIC int UTIL_prepareFileList(const char *dirName, char** bufStart, size_t* pos, char** bufE… in UTIL_prepareFileList() argument
481 …nbFiles += UTIL_prepareFileList(path, bufStart, pos, bufEnd); /* Recursively call "UTIL_prepareFi… in UTIL_prepareFileList()
482 if (*bufStart == NULL) { free(path); closedir(dir); return 0; } in UTIL_prepareFileList()
484 if (*bufStart + *pos + pathLength >= *bufEnd) { in UTIL_prepareFileList()
485 ptrdiff_t newListSize = (*bufEnd - *bufStart) + LIST_SIZE_INCREASE; in UTIL_prepareFileList()
486 *bufStart = (char*)UTIL_realloc(*bufStart, newListSize); in UTIL_prepareFileList()
487 *bufEnd = *bufStart + newListSize; in UTIL_prepareFileList()
488 if (*bufStart == NULL) { free(path); closedir(dir); return 0; } in UTIL_prepareFileList()
490 if (*bufStart + *pos + pathLength < *bufEnd) { in UTIL_prepareFileList()
491 strncpy(*bufStart + *pos, path, *bufEnd - (*bufStart + *pos)); in UTIL_prepareFileList()
502 free(*bufStart); in UTIL_prepareFileList()
503 *bufStart = NULL; in UTIL_prepareFileList()
511 UTIL_STATIC int UTIL_prepareFileList(const char *dirName, char** bufStart, size_t* pos, char** bufE… in UTIL_prepareFileList() argument
513 (void)bufStart; (void)bufEnd; (void)pos; in UTIL_prepareFileList()