diff options
| author | Dag-Erling Smørgrav <des@FreeBSD.org> | 2025-06-20 13:10:23 +0200 |
|---|---|---|
| committer | Dag-Erling Smørgrav <des@FreeBSD.org> | 2025-06-20 13:10:23 +0200 |
| commit | deeebfdecab56729fa898271ae53d01c8e156302 (patch) | |
| tree | de12e9d6e174f1b46c547a67a5ed22607300204c /include | |
| parent | 609720ed97b8de90ed2e9c8db6ea520076b76f11 (diff) | |
libc: Add fscandir(), fscandir_b(), scandirat_b().
While here, clean up scandir() a bit and improve the documentation.
MFC after: never
Sponsored by: Klara, Inc.
Reviewed by: markj
Differential Revision: https://reviews.freebsd.org/D50935
Diffstat (limited to 'include')
| -rw-r--r-- | include/dirent.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/include/dirent.h b/include/dirent.h index 460be40c1064..00319c0a8bd0 100644 --- a/include/dirent.h +++ b/include/dirent.h @@ -130,9 +130,22 @@ int scandir_b(const char *, struct dirent ***, #endif #endif #if __BSD_VISIBLE +int fscandir(int, struct dirent ***, + int (*)(const struct dirent *), int (*)(const struct dirent **, + const struct dirent **)); +#ifdef __BLOCKS__ +int fscandir_b(int, struct dirent ***, + int (^)(const struct dirent *), + int (^)(const struct dirent **, const struct dirent **)); +#endif int scandirat(int, const char *, struct dirent ***, int (*)(const struct dirent *), int (*)(const struct dirent **, const struct dirent **)); +#ifdef __BLOCKS__ +int scandirat_b(int, const char *, struct dirent ***, + int (^)(const struct dirent *), + int (^)(const struct dirent **, const struct dirent **)); +#endif #endif #if __XSI_VISIBLE void seekdir(DIR *, long); |
