From 63956e38b63f83d6aeba842294e5ab6f42c3521c Mon Sep 17 00:00:00 2001 From: guenther <> Date: Sat, 24 Mar 2012 01:53:51 +0000 Subject: [PATCH] Provide the old prototypes for scandir() and alphasort() for code that requests the pre-standardized version requested by millert@ --- src/include/dirent.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/include/dirent.h b/src/include/dirent.h index bebed33d..e5c08235 100644 --- a/src/include/dirent.h +++ b/src/include/dirent.h @@ -1,4 +1,4 @@ -/* $OpenBSD: dirent.h,v 1.27 2012/03/22 04:11:53 matthew Exp $ */ +/* $OpenBSD: dirent.h,v 1.28 2012/03/24 01:53:51 guenther Exp $ */ /* $NetBSD: dirent.h,v 1.9 1995/03/26 20:13:37 jtc Exp $ */ /*- @@ -98,6 +98,10 @@ int readdir_r(DIR *__restrict, struct dirent *__restrict, int scandir(const char *, struct dirent ***, int (*)(struct dirent *), int (*)(const struct dirent **, const struct dirent **)); int alphasort(const struct dirent **, const struct dirent **); +#elif __BSD_VISIBLE +int scandir(const char *, struct dirent ***, int (*)(struct dirent *), + int (*)(const void *, const void *)); +int alphasort(const void *, const void *); #endif #if __POSIX_VISIBLE >= 200809 || __XPG_VISIBLE > 600 int dirfd(DIR *);