summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2005-07-12 11:06:38 +0000
committerDaniel Stenberg <daniel@haxx.se>2005-07-12 11:06:38 +0000
commitdb4fb9558535d880179701d3bc7520bc8c7d69ce (patch)
treedd400df2c2bbea0629a5d56976c41dad3ebed2a8
parent2d8fd9cf8af10471800745e50895c8e0d90c6bc8 (diff)
downloadrockbox-db4fb9558535d880179701d3bc7520bc8c7d69ce.tar.gz
rockbox-db4fb9558535d880179701d3bc7520bc8c7d69ce.zip
make the ctype array unsigned so that bit 7 (octal 0200) can be set and
used properly without warnings git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7120 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--apps/plugin.h2
-rw-r--r--firmware/common/ctype.c36
-rw-r--r--firmware/include/ctype.h2
3 files changed, 20 insertions, 20 deletions
diff --git a/apps/plugin.h b/apps/plugin.h
index 36eccfe86f..c572ccbf65 100644
--- a/apps/plugin.h
+++ b/apps/plugin.h
@@ -285,7 +285,7 @@ struct plugin_api {
int (*strncasecmp)(const char *s1, const char *s2, size_t n);
void* (*memset)(void *dst, int c, size_t length);
void* (*memcpy)(void *out, const void *in, size_t n);
- const char *_ctype_;
+ const unsigned char *_ctype_;
int (*atoi)(const char *str);
char *(*strchr)(const char *s, int c);
char *(*strcat)(char *s1, const char *s2);
diff --git a/firmware/common/ctype.c b/firmware/common/ctype.c
index 651dacda86..6e9b4eb601 100644
--- a/firmware/common/ctype.c
+++ b/firmware/common/ctype.c
@@ -1,22 +1,22 @@
#include <ctype.h>
-const char _ctype_[257]={
- 0,
- _C, _C, _C, _C, _C, _C, _C, _C,
- _C, _C|_S, _C|_S, _C|_S, _C|_S, _C|_S, _C, _C,
- _C, _C, _C, _C, _C, _C, _C, _C,
- _C, _C, _C, _C, _C, _C, _C, _C,
- _S|_B, _P, _P, _P, _P, _P, _P, _P,
- _P, _P, _P, _P, _P, _P, _P, _P,
- _N, _N, _N, _N, _N, _N, _N, _N,
- _N, _N, _P, _P, _P, _P, _P, _P,
- _P, _U|_X, _U|_X, _U|_X, _U|_X, _U|_X, _U|_X, _U,
- _U, _U, _U, _U, _U, _U, _U, _U,
- _U, _U, _U, _U, _U, _U, _U, _U,
- _U, _U, _U, _P, _P, _P, _P, _P,
- _P, _L|_X, _L|_X, _L|_X, _L|_X, _L|_X, _L|_X, _L,
- _L, _L, _L, _L, _L, _L, _L, _L,
- _L, _L, _L, _L, _L, _L, _L, _L,
- _L, _L, _L, _P, _P, _P, _P, _C
+const unsigned char _ctype_[257]={
+ 0,
+ _C, _C, _C, _C, _C, _C, _C, _C,
+ _C, _C|_S, _C|_S, _C|_S, _C|_S, _C|_S, _C, _C,
+ _C, _C, _C, _C, _C, _C, _C, _C,
+ _C, _C, _C, _C, _C, _C, _C, _C,
+ _S|_B, _P, _P, _P, _P, _P, _P, _P,
+ _P, _P, _P, _P, _P, _P, _P, _P,
+ _N, _N, _N, _N, _N, _N, _N, _N,
+ _N, _N, _P, _P, _P, _P, _P, _P,
+ _P, _U|_X, _U|_X, _U|_X, _U|_X, _U|_X, _U|_X, _U,
+ _U, _U, _U, _U, _U, _U, _U, _U,
+ _U, _U, _U, _U, _U, _U, _U, _U,
+ _U, _U, _U, _P, _P, _P, _P, _P,
+ _P, _L|_X, _L|_X, _L|_X, _L|_X, _L|_X, _L|_X, _L,
+ _L, _L, _L, _L, _L, _L, _L, _L,
+ _L, _L, _L, _L, _L, _L, _L, _L,
+ _L, _L, _L, _P, _P, _P, _P, _C
};
diff --git a/firmware/include/ctype.h b/firmware/include/ctype.h
index f884b09f81..e0d20cc672 100644
--- a/firmware/include/ctype.h
+++ b/firmware/include/ctype.h
@@ -39,7 +39,7 @@ int _EXFUN(_toupper, (int __c));
#ifdef PLUGIN
#define _ctype_ (rb->_ctype_)
#else
-extern const char _ctype_[];
+extern const unsigned char _ctype_[257];
#endif
#ifndef __cplusplus