changeset 12236:c3904b8da3e8

10l: don't run strcmp if arg is NULL Pathc by adland
author rtognimp
date Mon, 19 Apr 2004 19:55:37 +0000
parents ca5dc9c2cb51
children ac1d23a37da7
files libmpdemux/network.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/libmpdemux/network.c	Mon Apr 19 02:14:09 2004 +0000
+++ b/libmpdemux/network.c	Mon Apr 19 19:55:37 2004 +0000
@@ -769,7 +769,7 @@
 						// If content-type == video/nsv we most likely have a winamp video stream 
 						// otherwise it should be mp3. if there are more types consider adding mime type 
 						// handling like later
-						if( !strcmp((field_data = http_get_field(http_hdr, "content-type")),"video/nsv"))
+				                if ( (field_data = http_get_field(http_hdr, "content-type")) != NULL && !strcmp(field_data, "video/nsv"))
 							*file_format = DEMUXER_TYPE_NSV;
 						else
 							*file_format = DEMUXER_TYPE_AUDIO;