2 * UCW Library -- Generic Shell-Like Pattern Matching (currently only '?' and '*')
4 * (c) 1997 Martin Mares <mj@ucw.cz>
6 * This software may be freely distributed and used according to the terms
7 * of the GNU Lesser General Public License.
10 #include "ucw/string.h"
13 MATCH_FUNC_NAME(const char *p, const char *s)
25 if (z == '\\' && p[2])
30 while (*s && Convert(*s) != z)
34 if (MATCH_FUNC_NAME(p+1, s))
41 if (*p == '\\' && p[1])
43 if (Convert(*p++) != Convert(*s++))