Query: gmatch
OS: centos
Section: 3gen
Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar
gmatch(3GEN) String Pattern-Matching Library Functions gmatch(3GEN)NAMEgmatch - shell global pattern matchingSYNOPSIScc [ flag ... ] file ... -lgen [ library ... ] #include <libgen.h> int gmatch(const char *str, const char *pattern);DESCRIPTIONgmatch() checks whether the null-terminated string str matches the null-terminated pattern string pattern. See the sh(1), section File Name Generation, for a discussion of pattern matching. A backslash () is used as an escape character in pattern strings.RETURN VALUESgmatch() returns non-zero if the pattern matches the string, zero if the pattern does not.EXAMPLESExample 1: Examples of gmatch() function. In the following example, gmatch() returns non-zero (true) for all strings with "a" or "-" as their last character. char *s; gmatch (s, "*[a-]" )ATTRIBUTESSee attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |MT-Level |MT-Safe | +-----------------------------+-----------------------------+SEE ALSOsh(1), attributes(5)NOTESWhen compiling multithreaded applications, the _REENTRANT flag must be defined on the compile line. This flag should only be used in mul- tithreaded applications. SunOS 5.10 29 Dec 1996 gmatch(3GEN)
Related Man Pages |
---|
gmatch(3gen) - sunos |
gmatch(3gen) - x11r4 |
gmatch(3gen) - v7 |
gmatch(3gen) - minix |
gmatch(3gen) - plan9 |
Similar Topics in the Unix Linux Community |
---|
Pattern Matching |
Pattern Matching |
Perl Pattern Matching:Unix Vs. Window (Is it OS dependent??) |
Help Needed Perl |
Pattern Matching in Perl script |