diff options
-rw-r--r-- | scummvm.cpp | 2 | ||||
-rw-r--r-- | sdl.cpp | 8 | ||||
-rw-r--r-- | simon/simon.cpp | 10 |
3 files changed, 12 insertions, 8 deletions
diff --git a/scummvm.cpp b/scummvm.cpp index 05e57d7efa..a4f4695e2a 100644 --- a/scummvm.cpp +++ b/scummvm.cpp @@ -293,8 +293,6 @@ int Scumm::scummLoop(int delta) } if (_completeScreenRedraw) { - int i; - Actor *a; _completeScreenRedraw = false; gdi.clearUpperMask(); charset._hasMask = false; @@ -208,7 +208,13 @@ void Normal3x(uint8 *srcPtr, uint32 srcPitch, uint8 *null, void atexit_proc() { SDL_ShowCursor(SDL_ENABLE); - SDL_Quit(); + + SDL_QuitSubSystem(SDL_INIT_VIDEO); + SDL_QuitSubSystem(SDL_INIT_TIMER); + SDL_QuitSubSystem(SDL_INIT_CDROM); +#ifndef WIN32 // FIXME: SDL bug - closing audio freezes w/ waveout + SDL_QuitSubSystem(SDL_INIT_AUDIO); +#endif } OSystem *OSystem_SDL::create(int gfx_mode, bool full_screen) { diff --git a/simon/simon.cpp b/simon/simon.cpp index 514b6a3dcc..d9a94df0a9 100644 --- a/simon/simon.cpp +++ b/simon/simon.cpp @@ -132,15 +132,15 @@ FILE *SimonState::fopen_maybe_lowercase(const char *filename) { const char *s = _game_path; strcpy(buf, s); strcat(buf, filename); - strcpy(dotbuf, buf); strcat(dotbuf, "."); // '.' appended version - // for dumb vfat drivers + strcpy(dotbuf, buf); strcat(dotbuf, "."); // '.' appended version + // for dumb vfat drivers /* original filename */ in = fopen(buf, "rb"); if (in) return in; /* lowercase original filename */ - e = buf; do *e = tolower(*e); while(*e++); + e = buf + strlen(s); do *e = tolower(*e); while(*e++); in = fopen(buf, "rb"); if (in) return in; @@ -152,9 +152,9 @@ FILE *SimonState::fopen_maybe_lowercase(const char *filename) { if (in) return in; /* lowercase dot appended */ - e = dotbuf; do *e = tolower(*e); while(*e++); + e = dotbuf + strlen(s); do *e = tolower(*e); while(*e++); in = fopen(dotbuf, "rb"); - warning("loading %s\n", dotbuf); + return in; } |