changeset 6418:2f0124b97014 libavformat

stream_selection can be freed in the fail case, in which case it's unassigned. Therefore, init it with NULL to prevent a crash on invalid streams. Patch by Zhentan Feng <spyfeng gmail com>.
author rbultje
date Sat, 28 Aug 2010 23:55:26 +0000
parents d2d2972c9715
children abd88124e6a9
files mmsh.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mmsh.c	Thu Aug 26 10:03:14 2010 +0000
+++ b/mmsh.c	Sat Aug 28 23:55:26 2010 +0000
@@ -214,7 +214,7 @@
 {
     int i, port, err;
     char httpname[256], path[256], host[128], location[1024];
-    char *stream_selection;
+    char *stream_selection = NULL;
     char headers[1024];
     MMSHContext *mmsh;
     MMSContext *mms;