fnmatch.h — filename-matching types
#include <fnmatch.h>
The <fnmatch.h> header shall define the following symbolic constants:
- FNM_NOMATCH
- The string does not match the specified pattern.
- FNM_PATHNAME
- <slash> in string only matches <slash> in pattern.
- FNM_PERIOD
- Leading <period> in string only matches <period> in pattern.
- FNM_NOESCAPE
- Disable backslash escaping.
- FNM_CASEFOLD
- Compare string and pattern in a case-insensitive manner. See 4.1 Case Insensitive Comparisons.
- FNM_IGNORECASE
- Equivalent to FNM_CASEFOLD.
The following shall be declared as a function and may also be defined as a macro. A function prototype shall be provided.
int fnmatch(const char *, const char *, int);
None.
None.
None.
XSH fnmatch
First released in Issue 4. Derived from the ISO POSIX-2 standard.
The FNM_NOSYS constant is marked obsolescent.
The obsolescent FNM_NOSYS constant is removed.
This reference page is clarified with respect to macros and symbolic constants.
Austin Group Defect 1031 is applied, adding FNM_CASEFOLD and FNM_IGNORECASE.
The description of FNM_PERIOD is updated to eliminate the use of "must".
return to top of page