aboutsummaryrefslogtreecommitdiff
path: root/backends/sdl
diff options
context:
space:
mode:
authorMax Horn2003-05-28 22:19:11 +0000
committerMax Horn2003-05-28 22:19:11 +0000
commit73c7e78f888f3e49e7b744ee68efeded21be0545 (patch)
tree58098a0b651bbd716dcb8d06efd8cf556cf75006 /backends/sdl
parent2aaa13438a90543f35f98a233074878b63307cfe (diff)
downloadscummvm-rg350-73c7e78f888f3e49e7b744ee68efeded21be0545.tar.gz
scummvm-rg350-73c7e78f888f3e49e7b744ee68efeded21be0545.tar.bz2
scummvm-rg350-73c7e78f888f3e49e7b744ee68efeded21be0545.zip
fix for the crash in Sky when switching scalers
svn-id: r8067
Diffstat (limited to 'backends/sdl')
-rw-r--r--backends/sdl/sdl.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/backends/sdl/sdl.cpp b/backends/sdl/sdl.cpp
index a00d00162c..0b3e29018b 100644
--- a/backends/sdl/sdl.cpp
+++ b/backends/sdl/sdl.cpp
@@ -204,6 +204,8 @@ void OSystem_SDL::hotswap_gfx_mode() {
if (!_screen)
return;
+ StackLock lock(_mutex); // Lock the mutex until this function ends
+
// Keep around the old _screen & _tmpscreen so we can restore the screen data
// after the mode switch.
SDL_Surface *old_screen = _screen;