[MPlayer-cvslog] r37669 - trunk/stream/stream_dvb.c

reimar subversion at mplayerhq.hu
Thu Feb 11 20:40:24 CET 2016


Author: reimar
Date: Thu Feb 11 20:40:23 2016
New Revision: 37669

Log:
stream_dvb: Fix memleak.

Overwriting a pointer to allocated memory
is not a good idea.
Add a default switch case instead.

Modified:
   trunk/stream/stream_dvb.c

Modified: trunk/stream/stream_dvb.c
==============================================================================
--- trunk/stream/stream_dvb.c	Wed Feb 10 23:25:28 2016	(r37668)
+++ trunk/stream/stream_dvb.c	Thu Feb 11 20:40:23 2016	(r37669)
@@ -797,7 +797,6 @@ dvb_config_t *dvb_get_config(void)
 			continue;
 		}
 
-		conf_file = get_path("channels.conf");
 		switch(type)
 		{
 			case TUNER_TER:
@@ -812,6 +811,9 @@ dvb_config_t *dvb_get_config(void)
 			case TUNER_ATSC:
 			conf_file = get_path("channels.conf.atsc");
 				break;
+			default:
+			conf_file = get_path("channels.conf");
+				break;
 		}
 
 		if((access(conf_file, F_OK | R_OK) != 0))


More information about the MPlayer-cvslog mailing list