mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-09-05 19:08:12 +00:00
Fix Conditional jump or move depends on uninitialised value(s)
eg ./testsprite2 --trackmem
This commit is contained in:
@@ -228,6 +228,12 @@ void SDLTest_LogAllocations()
|
||||
return;
|
||||
}
|
||||
|
||||
message = SDL_realloc_orig(NULL, 1);
|
||||
if (!message) {
|
||||
return;
|
||||
}
|
||||
*message = 0;
|
||||
|
||||
#define ADD_LINE() \
|
||||
message_size += (SDL_strlen(line) + 1); \
|
||||
tmp = (char *)SDL_realloc_orig(message, message_size); \
|
||||
|
Reference in New Issue
Block a user