Mercurial > hg > octave-jordi > gnulib-hg
diff lib/c-strcasestr.c @ 12421:e8d2c6fc33ad
Use spaces for indentation, not tabs.
author | Bruno Haible <bruno@clisp.org> |
---|---|
date | Thu, 10 Dec 2009 20:28:30 +0100 (2009-12-10) |
parents | 729b6d4ffac1 |
children | b5e42ef33b49 |
line wrap: on
line diff
--- a/lib/c-strcasestr.c +++ b/lib/c-strcasestr.c @@ -28,11 +28,11 @@ /* Two-Way algorithm. */ #define RETURN_TYPE char * -#define AVAILABLE(h, h_l, j, n_l) \ - (!memchr ((h) + (h_l), '\0', (j) + (n_l) - (h_l)) \ +#define AVAILABLE(h, h_l, j, n_l) \ + (!memchr ((h) + (h_l), '\0', (j) + (n_l) - (h_l)) \ && ((h_l) = (j) + (n_l))) #define CANON_ELEMENT c_tolower -#define CMP_FUNC(p1, p2, l) \ +#define CMP_FUNC(p1, p2, l) \ c_strncasecmp ((const char *) (p1), (const char *) (p2), l) #include "str-two-way.h" @@ -52,7 +52,7 @@ NEEDLE if HAYSTACK is too short). */ while (*haystack && *needle) ok &= (c_tolower ((unsigned char) *haystack++) - == c_tolower ((unsigned char) *needle++)); + == c_tolower ((unsigned char) *needle++)); if (*needle) return NULL; if (ok) @@ -66,12 +66,12 @@ ISO C 99 section 6.2.6.1. */ if (needle_len < LONG_NEEDLE_THRESHOLD) return two_way_short_needle ((const unsigned char *) haystack, - haystack_len, - (const unsigned char *) needle_start, - needle_len); + haystack_len, + (const unsigned char *) needle_start, + needle_len); return two_way_long_needle ((const unsigned char *) haystack, haystack_len, - (const unsigned char *) needle_start, - needle_len); + (const unsigned char *) needle_start, + needle_len); } #undef LONG_NEEDLE_THRESHOLD