mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-06-11 17:05:41 +00:00
Fixed memory leak getting the X11 window title
This commit is contained in:
parent
05cff7923c
commit
66a88c6c97
1 changed files with 1 additions and 0 deletions
|
|
@ -643,6 +643,7 @@ X11_GetWindowTitle(_THIS, Window xwindow)
|
|||
&items_read, &items_left, &propdata);
|
||||
if (status == Success && propdata) {
|
||||
title = SDL_iconv_string("UTF-8", "", SDL_static_cast(char*, propdata), items_read+1);
|
||||
X11_XFree(propdata);
|
||||
} else {
|
||||
title = SDL_strdup("");
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue