summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libmpdemux/open.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libmpdemux/open.c b/libmpdemux/open.c
index 5fa7a316b2..a57861991f 100644
--- a/libmpdemux/open.c
+++ b/libmpdemux/open.c
@@ -86,9 +86,9 @@ int bsize = VCD_SECTOR_SIZE;
#endif
#ifdef HAVE_CDDA
-if(strncmp("cdda://",filename,7) == 0)
+if(filename && strncmp("cdda://",filename,7) == 0)
return open_cdda(cdrom_device ? cdrom_device : DEFAULT_CDROM_DEVICE,filename+7);
-if(strncmp("cddb://",filename,7) == 0)
+if(filename && strncmp("cddb://",filename,7) == 0)
return cddb_open(cdrom_device ? cdrom_device : DEFAULT_CDROM_DEVICE,filename+7);
#endif