diff options
author | Rich Felker <dalias@aerifal.cx> | 2012-01-22 15:49:42 -0500 |
---|---|---|
committer | Rich Felker <dalias@aerifal.cx> | 2012-01-22 15:49:42 -0500 |
commit | 787c2648a9bdc9431237abc0fdd61971cbf289cd (patch) | |
tree | 57b2659c05314763a7fe34ff83ba8695b9d16698 | |
parent | 4904b64275d76e9a9f6f26ee3586dc600cce9ded (diff) | |
download | musl-787c2648a9bdc9431237abc0fdd61971cbf289cd.tar.gz |
support GLOB_PERIOD flag (GNU extension) to glob function
patch by sh4rm4
-rw-r--r-- | src/regex/glob.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/regex/glob.c b/src/regex/glob.c index 550f655c..bbe78f7d 100644 --- a/src/regex/glob.c +++ b/src/regex/glob.c @@ -58,7 +58,8 @@ static int match_in_dir(const char *d, const char *p, int flags, int (*errfunc)( char *p2; size_t l = strlen(d); int literal; - int fnm_flags= ((flags & GLOB_NOESCAPE) ? FNM_NOESCAPE : 0) | FNM_PERIOD; + int fnm_flags= ((flags & GLOB_NOESCAPE) ? FNM_NOESCAPE : 0) + | ((!(flags & GLOB_PERIOD)) ? FNM_PERIOD : 0); int error; if ((p2 = strchr(p, '/'))) { |