diff --git a/CHANGELOG.md b/CHANGELOG.md index 168d03310a..fe266a066e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -140,6 +140,7 @@ Bug #6818: ess-importer doesn't exactly reproduce camera Bug #6849: ImageButton texture is not scaled properly Bug #6869: Hits queue stagger during swing animation + Bug #6890: SDL_PeepEvents errors are not handled Bug #6895: Removing a negative number of items from a script, makes the script terminate with an error Bug #6898: Accessing the Quick Inventory menu does not work while in menu mode Bug #6901: Morrowind.exe soul gem usage discrepancy diff --git a/components/sdlutil/sdlinputwrapper.cpp b/components/sdlutil/sdlinputwrapper.cpp index 3bd74f569a..8f8396c36d 100644 --- a/components/sdlutil/sdlinputwrapper.cpp +++ b/components/sdlutil/sdlinputwrapper.cpp @@ -53,7 +53,7 @@ InputWrapper::InputWrapper(SDL_Window* window, osg::ref_ptr v if (windowEventsOnly) { // During loading, handle window events, discard button presses and keep others for later - while (SDL_PeepEvents(&evt, 1, SDL_GETEVENT, SDL_WINDOWEVENT, SDL_WINDOWEVENT)) + while (SDL_PeepEvents(&evt, 1, SDL_GETEVENT, SDL_WINDOWEVENT, SDL_WINDOWEVENT) > 0) handleWindowEvent(evt); SDL_FlushEvent(SDL_KEYDOWN);