summaryrefslogtreecommitdiffstats
path: root/lib/libc/gen/glob.3
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libc/gen/glob.3')
-rw-r--r--lib/libc/gen/glob.317
1 files changed, 17 insertions, 0 deletions
diff --git a/lib/libc/gen/glob.3 b/lib/libc/gen/glob.3
index c643aaa..efc413c 100644
--- a/lib/libc/gen/glob.3
+++ b/lib/libc/gen/glob.3
@@ -260,6 +260,14 @@ character, avoiding any special interpretation of the character.
Expand patterns that start with
.Ql ~
to user name home directories.
+.It Dv GLOB_MAXPATH
+Limit the total number of returned pathnames to the value provided in
+.Fa gl_matchc .
+If
+.Fn glob
+would match more pathnames,
+.Dv GLOB_LIMIT
+will be returned.
.El
.Pp
If, during the search, a directory is encountered that cannot be opened
@@ -376,6 +384,14 @@ The scan was stopped because an error was encountered and either
was set or
.Fa \*(lp*errfunc\*(rp\*(lp\*(rp
returned non-zero.
+.It Dv GLOB_LIMIT
+The flag
+.Dv GLOB_MAXPATH
+was provided, and the specified limit passed to
+.Fn glob
+in
+.Fa pglob\->gl_matchc
+was reached.
.El
.Pp
The arguments
@@ -412,6 +428,7 @@ that the flags
.Dv GLOB_ALTDIRFUNC ,
.Dv GLOB_BRACE ,
.Dv GLOB_MAGCHAR ,
+.Dv GLOB_MAXPATH ,
.Dv GLOB_NOMAGIC ,
.Dv GLOB_QUOTE ,
and
OpenPOWER on IntegriCloud