diff --git a/Gui/interface.c b/Gui/interface.c index 8c831c0f6f..d4bb15b732 100644 --- a/Gui/interface.c +++ b/Gui/interface.c @@ -84,7 +84,7 @@ void guiInit( void ) gtkAOOSSDevice=strdup( PATH_DEV_DSP ); cfg_read(); appInit( (void*)mDisplay ); - if ( plCurrent ) mplSetFileName( plCurrent->path,plCurrent->name ); + if ( plCurrent && !filename ) mplSetFileName( plCurrent->path,plCurrent->name ); #if defined( USE_OSD ) || defined( USE_SUB ) guiLoadFont(); #endif @@ -315,7 +315,7 @@ void guiGetEvent( int type,char * arg ) #endif break; case guiSetDefaults: - if ( filename && gstrcmp( filename,guiIntfStruct.Filename ) ) + if ( filename && !guiIntfStruct.Filename ) { gtkSet( gtkDelPl,0,NULL ); guiIntfStruct.StreamType=STREAMTYPE_FILE; guiSetFilename( guiIntfStruct.Filename,filename ); diff --git a/Gui/mplayer/play.c b/Gui/mplayer/play.c index 5c400be489..d51328132e 100644 --- a/Gui/mplayer/play.c +++ b/Gui/mplayer/play.c @@ -97,8 +97,8 @@ void mplEnd( void ) guiSetDF( guiIntfStruct.Filename,next->path,next->name ); guiIntfStruct.StreamType=STREAMTYPE_FILE; guiIntfStruct.FilenameChanged=1; - if ( guiIntfStruct.AudioFile ) free( guiIntfStruct.AudioFile ); - guiIntfStruct.AudioFile=NULL; + gfree( (void **)&guiIntfStruct.AudioFile ); + gfree( (void **)&guiIntfStruct.Subtitlename ); } else {