diff options
author | Bruno Haible <bruno@clisp.org> | 2008-12-22 12:11:44 +0100 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2008-12-22 12:11:44 +0100 |
commit | 4eda4ba54f3cf29f6b7fe4458e719cd2325be4c4 (patch) | |
tree | 73f83433f8d40c84f098fb4e179b97f1dbcc2cba /lib/mbschr.c | |
parent | 3e2e5dc1f6ded97ce60498e3ceb67fca5a41b8a8 (diff) | |
download | gnulib-4eda4ba54f3cf29f6b7fe4458e719cd2325be4c4.tar.gz |
Remove HAVE_MBRTOWC conditionals. Use mbrtowc unconditionally.
Diffstat (limited to 'lib/mbschr.c')
-rw-r--r-- | lib/mbschr.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/lib/mbschr.c b/lib/mbschr.c index 5997b18cfd..ec1ebac053 100644 --- a/lib/mbschr.c +++ b/lib/mbschr.c @@ -1,5 +1,5 @@ /* Searching a string for a character. - Copyright (C) 2007 Free Software Foundation, Inc. + Copyright (C) 2007-2008 Free Software Foundation, Inc. Written by Bruno Haible <bruno@clisp.org>, 2007. This program is free software: you can redistribute it and/or modify @@ -20,16 +20,13 @@ /* Specification. */ #include <string.h> -#if HAVE_MBRTOWC -# include "mbuiter.h" -#endif +#include "mbuiter.h" /* Locate the first single-byte character C in the character string STRING, and return a pointer to it. Return NULL if C is not found in STRING. */ char * mbschr (const char *string, int c) { -#if HAVE_MBRTOWC if (MB_CUR_MAX > 1 /* Optimization: We know that ASCII characters < 0x30 don't occur as part of multibyte characters longer than 1 byte. Hence, if c < 0x30, @@ -51,6 +48,5 @@ mbschr (const char *string, int c) return NULL; } else -#endif return strchr (string, c); } |