false-use-of-get_path() memleak fixes.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@12891 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
al
2004-07-23 16:10:21 +00:00
parent ea3e5fdf2e
commit 8bad258e0d
2 changed files with 12 additions and 4 deletions

View File

@@ -1484,7 +1484,10 @@ mp_input_init(void) {
if(!file)
return;
if(! mp_input_parse_config(file)) {
if( mp_input_parse_config(file)) {
free(file); // release the buffer created by get_path()
}
else {
// Try global conf dir
file = MPLAYER_CONFDIR "/input.conf";
if(! mp_input_parse_config(file))