changeset 35536:1c2cb32a4af9

Check availability of mixer before rendering.
author ib
date Sun, 09 Dec 2012 12:23:56 +0000
parents dad7efd97bbb
children 82f34397ebdb
files gui/ui/render.c
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/gui/ui/render.c	Sun Dec 09 12:16:14 2012 +0000
+++ b/gui/ui/render.c	Sun Dec 09 12:23:56 2012 +0000
@@ -43,7 +43,7 @@
     char tmp[512];
     unsigned int i, c;
     int t;
-    mixer_t *mixer;
+    mixer_t *mixer = NULL;
 
     *trbuf = 0;
 
@@ -170,9 +170,10 @@
 
             case 'a':
 
+                if (guiInfo.mpcontext)
                 mixer = mpctx_get_mixer(guiInfo.mpcontext);
 
-                if (mixer->muted) {
+                if (mixer && mixer->muted) {
                     av_strlcat(trbuf, "n", sizeof(trbuf));
                     break;
                 }