aboutsummaryrefslogtreecommitdiff
path: root/base/commandLine.cpp
diff options
context:
space:
mode:
authorMax Horn2012-01-28 01:15:49 +0100
committerMax Horn2012-02-15 16:51:37 +0100
commit658080deeda79d20ea40643569fbcb072573e7cf (patch)
treed604bf668909a6db44a1ec83e7c51088a5d85592 /base/commandLine.cpp
parent37e5b209a71af725456a42be2605dea28ffceb84 (diff)
downloadscummvm-rg350-658080deeda79d20ea40643569fbcb072573e7cf.tar.gz
scummvm-rg350-658080deeda79d20ea40643569fbcb072573e7cf.tar.bz2
scummvm-rg350-658080deeda79d20ea40643569fbcb072573e7cf.zip
ALL: Avoid using is* macros from ctype.h
On some systems, passing signed chars to macros like isspace() etc. lead to a runtime error. Hence, mark these macros as forbidden by default, and introduce otherwise equivalent alternatives for them.
Diffstat (limited to 'base/commandLine.cpp')
-rw-r--r--base/commandLine.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/base/commandLine.cpp b/base/commandLine.cpp
index c3059ced2f..16a2b6f9f0 100644
--- a/base/commandLine.cpp
+++ b/base/commandLine.cpp
@@ -277,7 +277,7 @@ void registerDefaults() {
// resp. between "--some-option" and "--no-some-option".
#define DO_OPTION_BOOL(shortCmd, longCmd) \
if (isLongCmd ? (!strcmp(s+2, longCmd) || !strcmp(s+2, "no-"longCmd)) : (tolower(s[1]) == shortCmd)) { \
- bool boolValue = (islower(static_cast<unsigned char>(s[1])) != 0); \
+ bool boolValue = (isLower(s[1]) != 0); \
s += 2; \
if (isLongCmd) { \
boolValue = !strcmp(s, longCmd); \