diff options
author | Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com> | 2018-04-19 15:21:54 -0300 |
---|---|---|
committer | Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com> | 2018-04-19 15:21:54 -0300 |
commit | 70ae2309a84496e287d721cf88a1c916c2a2c971 (patch) | |
tree | db32edc81ee3df28aed67a192a6a0c5def226942 /posix/glob_pattern_p.c | |
parent | 15a05fafa4d7f94ae5002803ad8384519479469b (diff) | |
parent | 49a0c33ead1b1eea5b414e9e2574a4fd96291203 (diff) | |
download | glibc-ibm/2.22/master.tar.gz |
Merge branch 'release/2.22/master' into ibm/2.22/masteribm/2.22/master
Diffstat (limited to 'posix/glob_pattern_p.c')
-rw-r--r-- | posix/glob_pattern_p.c | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/posix/glob_pattern_p.c b/posix/glob_pattern_p.c new file mode 100644 index 0000000000..a17d337182 --- /dev/null +++ b/posix/glob_pattern_p.c @@ -0,0 +1,33 @@ +/* Return nonzero if PATTERN contains any metacharacters. + Copyright (C) 2017 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + The GNU C Library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with the GNU C Library; if not, see + <http://www.gnu.org/licenses/>. */ + +#ifndef _LIBC +# include <config.h> +#endif + +#include <glob.h> +#include "glob_internal.h" + +/* Return nonzero if PATTERN contains any metacharacters. + Metacharacters can be quoted with backslashes if QUOTE is nonzero. */ +int +__glob_pattern_p (const char *pattern, int quote) +{ + return __glob_pattern_type (pattern, quote) == 1; +} +weak_alias (__glob_pattern_p, glob_pattern_p) |