Mercurial > mplayer.hg
changeset 36833:5691f930dca6
Fix bug with Win32 GUI preferences.
Fix memory leak by freeing proc_priority.
author | ib |
---|---|
date | Mon, 24 Feb 2014 14:25:53 +0000 |
parents | 17d0c4e89555 |
children | b2e529a2cbab |
files | gui/win32/preferences.c |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/gui/win32/preferences.c Mon Feb 24 13:15:23 2014 +0000 +++ b/gui/win32/preferences.c Mon Feb 24 14:25:53 2014 +0000 @@ -32,6 +32,7 @@ #include "osdep/priority.h" #include "mixer.h" #include "gui/util/list.h" +#include "gui/util/string.h" #include "gui/ui/ui.h" #include "gui/interface.h" #include "gui.h" @@ -539,7 +540,7 @@ /* Set the priority level */ SendMessage(prio, CB_GETLBTEXT, (WPARAM)SendMessage(prio, CB_GETCURSEL, 0, 0), (LPARAM)procprio); - proc_priority = strdup(procprio); + setdup(&proc_priority, procprio); /* double buffering */ if(SendDlgItemMessage(hwnd, ID_DOUBLE, BM_GETCHECK, 0, 0) == BST_CHECKED)