aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMax Horn2006-04-02 20:29:54 +0000
committerMax Horn2006-04-02 20:29:54 +0000
commit5e4c6c76b16df3acfdd168b73de36f61a80249a5 (patch)
tree7958510121713dc0181fcc3173ed2faa2f786217
parentf600fd973ada197976154b781e018cde604811d6 (diff)
downloadscummvm-rg350-5e4c6c76b16df3acfdd168b73de36f61a80249a5.tar.gz
scummvm-rg350-5e4c6c76b16df3acfdd168b73de36f61a80249a5.tar.bz2
scummvm-rg350-5e4c6c76b16df3acfdd168b73de36f61a80249a5.zip
Fixed '-f BAR' command line argument style (as opposed to '-fBAR' and '-foo=BAR')
svn-id: r21565
-rw-r--r--base/gameDetector.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/base/gameDetector.cpp b/base/gameDetector.cpp
index 3ecc7cd892..4ce65973de 100644
--- a/base/gameDetector.cpp
+++ b/base/gameDetector.cpp
@@ -321,7 +321,8 @@ GameDescriptor GameDetector::findGame(const String &gameName, const Plugin **plu
if (isLongCmd ? (!memcmp(s, longCmd"=", sizeof(longCmd"=") - 1)) : (shortCmdLower == shortCmd)) { \
if (isLongCmd) \
s += sizeof(longCmd"=") - 1; \
- const char *option = (*s != '\0') ? s : s2; \
+ const char *option = s; \
+ if (*s == '\0') { option = s2; i++; } \
if (!option) option = defaultVal; \
if (option) settings[longCmd] = option;