There are legitimate reasons to skip full cleanup at shutdown, don't assert in that case.
authorSam Lantinga <slouken@libsdl.org>
Mon, 08 Oct 2018 12:49:23 -0700
changeset 1230427ba030d839f
parent 12299 d8683d6ff2f8
child 12305 85c6aa0836d8
There are legitimate reasons to skip full cleanup at shutdown, don't assert in that case.
src/haptic/SDL_haptic.c
     1.1 --- a/src/haptic/SDL_haptic.c	Fri Oct 05 17:06:05 2018 -0700
     1.2 +++ b/src/haptic/SDL_haptic.c	Mon Oct 08 12:49:23 2018 -0700
     1.3 @@ -389,9 +389,11 @@
     1.4  void
     1.5  SDL_HapticQuit(void)
     1.6  {
     1.7 +    while (SDL_haptics) {
     1.8 +        SDL_HapticClose(SDL_haptics);
     1.9 +    }
    1.10 +
    1.11      SDL_SYS_HapticQuit();
    1.12 -    SDL_assert(SDL_haptics == NULL);
    1.13 -    SDL_haptics = NULL;
    1.14  }
    1.15  
    1.16  /*