From 068042781feca5ddd1a1cc0f36a8c842773d994a Mon Sep 17 00:00:00 2001 From: Ruediger Hanke Date: Tue, 17 Sep 2002 21:45:13 +0000 Subject: Appending a slash in all cases breaks some games on MOS svn-id: r4961 --- common/file.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'common/file.cpp') diff --git a/common/file.cpp b/common/file.cpp index bce682a9be..7812d1f067 100644 --- a/common/file.cpp +++ b/common/file.cpp @@ -30,6 +30,9 @@ FILE *File::fopenNoCase(const char *filename, const char * directory, const char strcpy(buf, directory); if (directory[0] != 0) { strcpy(buf, directory); +#ifdef __MORPHOS__ + if (buf[strlen(buf)-1] != ':' && buf[strlen(buf)-1] != '/') +#endif strcat(buf, "/"); } strcat(buf, filename); @@ -51,6 +54,9 @@ FILE *File::fopenNoCase(const char *filename, const char * directory, const char strcpy(buf, directory); if (directory[0] != 0) { strcpy(buf, directory); +#ifdef __MORPHOS__ + if (buf[strlen(buf)-1] != ':' && buf[strlen(buf)-1] != '/') +#endif strcat(buf, "/"); } strcat(buf, dirs[l]); -- cgit v1.2.3