]>
diplodocus.org Git - nmh/blob - sbr/uprf.c
3 * uprf.c -- "unsigned" lexical prefix
5 * This code is Copyright (c) 2002, by the authors of nmh. See the
6 * COPYRIGHT file in the root directory of the nmh distribution for
7 * complete copyright information.
13 /* uprf returns true if s starts with prefix, ignoring case.
14 * Otherwise false. If s or prefix are NULL then false results. */
16 uprf(const char *s
, const char *prefix
)
18 unsigned char *us
, *up
;
22 us
= (unsigned char *)s
;
23 up
= (unsigned char *)prefix
;
25 while (*us
&& tolower(*us
) == tolower(*up
)) {