Browse Source

SDL_thread.c: fix unused function SDL_FreeErrBuf when building without thread support (emscripten)

Anonymous Maarten 2 years ago
parent
commit
2105c7f6ed
1 changed files with 2 additions and 0 deletions
  1. 2 0
      src/thread/SDL_thread.c

+ 2 - 0
src/thread/SDL_thread.c

@@ -211,6 +211,7 @@ SDL_GetStaticErrBuf()
     return &SDL_global_error;
     return &SDL_global_error;
 }
 }
 
 
+#if !SDL_THREADS_DISABLED
 static void SDLCALL
 static void SDLCALL
 SDL_FreeErrBuf(void *data)
 SDL_FreeErrBuf(void *data)
 {
 {
@@ -221,6 +222,7 @@ SDL_FreeErrBuf(void *data)
     }
     }
     errbuf->free_func(errbuf);
     errbuf->free_func(errbuf);
 }
 }
+#endif
 
 
 /* Routine to get the thread-specific error variable */
 /* Routine to get the thread-specific error variable */
 SDL_error *
 SDL_error *