mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-06-06 14:43:20 +00:00
Replace SDL_free with delete for new-allocated objects
This commit is contained in:
parent
5bee85408c
commit
e7a765d648
1 changed files with 3 additions and 3 deletions
|
|
@ -251,9 +251,9 @@ void SDL_SYS_ShowFileDialogWithProperties(SDL_FileDialogType type, SDL_DialogFil
|
|||
SDLBRefFilter *filter = new(std::nothrow) SDLBRefFilter(filters, nfilters);
|
||||
|
||||
if (looper == NULL || messenger == NULL || filter == NULL) {
|
||||
SDL_free(looper);
|
||||
SDL_free(messenger);
|
||||
SDL_free(filter);
|
||||
delete looper;
|
||||
delete messenger;
|
||||
delete filter;
|
||||
SDL_OutOfMemory();
|
||||
callback(userdata, NULL, -1);
|
||||
return;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue