summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorglx <glx@openttd.org>2008-04-23 13:36:52 +0000
committerglx <glx@openttd.org>2008-04-23 13:36:52 +0000
commite3ca91dc1508edd858e0f03e73de7e0519a8f30d (patch)
treec3fc032b8b11668278540bea8447bee91addb117
parent24cccc83332476b7453368db9cad9570a602ec63 (diff)
downloadopenttd-e3ca91dc1508edd858e0f03e73de7e0519a8f30d.tar.xz
(svn r12850) -Fix (r12848): compilation was broken for some platforms
-rw-r--r--src/fios.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/fios.cpp b/src/fios.cpp
index 726e72a0f..52abf872f 100644
--- a/src/fios.cpp
+++ b/src/fios.cpp
@@ -111,11 +111,15 @@ char *FiosBrowseTo(const FiosItem *item)
char *path = _fios_path;
switch (item->type) {
+ case FIOS_TYPE_DRIVE:
#if defined(WINCE)
- case FIOS_TYPE_DRIVE: sprintf(path, PATHSEP ""); break;
+ sprintf(path, PATHSEP "");
#elif defined(WIN32) || defined(__OS2__)
- case FIOS_TYPE_DRIVE: sprintf(path, "%c:" PATHSEP, item->title[0]); break;
+ sprintf(path, "%c:" PATHSEP, item->title[0]);
#endif
+ /* Fallthrough */
+ case FIOS_TYPE_INVALID:
+ break;
case FIOS_TYPE_PARENT: {
/* Check for possible NULL ptr (not required for UNIXes, but AmigaOS-alikes) */
@@ -152,10 +156,6 @@ char *FiosBrowseTo(const FiosItem *item)
snprintf(str_buffr, lengthof(str_buffr), "%s%s", path, item->name);
return str_buffr;
}
-
- case FIOS_TYPE_DRIVE:
- case FIOS_TYPE_INVALID:
- break;
}
return NULL;