summaryrefslogtreecommitdiff
path: root/openbsd-compat/glob.c
diff options
context:
space:
mode:
Diffstat (limited to 'openbsd-compat/glob.c')
-rw-r--r--openbsd-compat/glob.c17
1 files changed, 14 insertions, 3 deletions
diff --git a/openbsd-compat/glob.c b/openbsd-compat/glob.c
index f6a04ea3f..b3dd2b171 100644
--- a/openbsd-compat/glob.c
+++ b/openbsd-compat/glob.c
@@ -34,7 +34,21 @@
34/* OPENBSD ORIGINAL: lib/libc/gen/glob.c */ 34/* OPENBSD ORIGINAL: lib/libc/gen/glob.c */
35 35
36#include "includes.h" 36#include "includes.h"
37
38#include <sys/types.h>
39#include <sys/stat.h>
40
41#include <dirent.h>
37#include <ctype.h> 42#include <ctype.h>
43#include <errno.h>
44#include <pwd.h>
45#include <stdlib.h>
46#include <string.h>
47#include <unistd.h>
48
49#if !defined(HAVE_GLOB) || !defined(GLOB_HAS_ALTDIRFUNC) || \
50 !defined(GLOB_HAS_GL_MATCHC) || \
51 !defined(HAVE_DECL_GLOB_NOMATCH) || HAVE_DECL_GLOB_NOMATCH == 0
38 52
39static long 53static long
40get_arg_max(void) 54get_arg_max(void)
@@ -48,9 +62,6 @@ get_arg_max(void)
48#endif 62#endif
49} 63}
50 64
51#if !defined(HAVE_GLOB) || !defined(GLOB_HAS_ALTDIRFUNC) || \
52 !defined(GLOB_HAS_GL_MATCHC)
53
54/* 65/*
55 * glob(3) -- a superset of the one defined in POSIX 1003.2. 66 * glob(3) -- a superset of the one defined in POSIX 1003.2.
56 * 67 *