[MPlayer-cvslog] r38072 - trunk/gui/interface.c

ib subversion at mplayerhq.hu
Thu Apr 12 15:53:41 EEST 2018


Author: ib
Date: Thu Apr 12 15:53:41 2018
New Revision: 38072

Log:
Don't continue in case of an evLoadSubtitle error.

Calling update_set_of_subtitles() in case of a sub_read_file() error
would delete the currently used subtitle instead of loading a new one.

Modified:
   trunk/gui/interface.c

Modified: trunk/gui/interface.c
==============================================================================
--- trunk/gui/interface.c	Thu Apr 12 15:46:21 2018	(r38071)
+++ trunk/gui/interface.c	Thu Apr 12 15:53:41 2018	(r38072)
@@ -1420,8 +1420,10 @@ void mplayerLoadSubtitle(const char *nam
 
         subdata = sub_read_file(name, guiInfo.sh_video ? guiInfo.sh_video->fps : 0);
 
-        if (!subdata)
+        if (!subdata) {
             gmp_msg(MSGT_GPLAYER, MSGL_ERR, MSGTR_CantLoadSub, name);
+            return;
+        }
     }
 
     update_set_of_subtitles();


More information about the MPlayer-cvslog mailing list