diff --git a/backends/sdl/sdl-common.cpp b/backends/sdl/sdl-common.cpp index 92eca7acf88..2e4748b4151 100644 --- a/backends/sdl/sdl-common.cpp +++ b/backends/sdl/sdl-common.cpp @@ -103,7 +103,10 @@ OSystem_SDL_Common::OSystem_SDL_Common() _cdrom(0), _dirty_checksums(0), _mouseVisible(false), _mouseDrawn(false), _mouseData(0), _mouseHotspotX(0), _mouseHotspotY(0), - _currentShakePos(0), _newShakePos(0) { + _currentShakePos(0), _newShakePos(0), + _paletteDirtyStart(0), _paletteDirtyEnd(0), + _mutex(0) { + // allocate palette storage _currentPalette = (SDL_Color *)calloc(sizeof(SDL_Color), 256); @@ -112,8 +115,6 @@ OSystem_SDL_Common::OSystem_SDL_Common() // reset mouse state memset(&km, 0, sizeof(km)); - - _mutex = 0; } OSystem_SDL_Common::~OSystem_SDL_Common() {