mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-06-06 07:20:48 +00:00
dialog: Allocate space for terminator when building filter string
This commit is contained in:
parent
fdcc3e1151
commit
65a04a772e
1 changed files with 1 additions and 1 deletions
|
@ -54,7 +54,7 @@ char *convert_filters(const SDL_DialogFileFilter *filters, NameTransform ntf,
|
|||
|
||||
terminator = f[1].name ? separator : suffix;
|
||||
new_length = SDL_strlen(combined) + SDL_strlen(converted)
|
||||
+ SDL_strlen(terminator);
|
||||
+ SDL_strlen(terminator) + 1;
|
||||
|
||||
new_combined = SDL_realloc(combined, new_length);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue