lavd/pulse_audio_enc: add another default to stream name
authorLukasz Marek <lukasz.m.luki@gmail.com>
Thu, 24 Oct 2013 16:10:06 +0000 (18:10 +0200)
committerLukasz Marek <lukasz.m.luki@gmail.com>
Fri, 25 Oct 2013 23:58:01 +0000 (01:58 +0200)
Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
libavdevice/pulse_audio_enc.c

index 5343696..86ef648 100644 (file)
@@ -59,8 +59,12 @@ static av_cold int pulse_write_header(AVFormatContext *h)
         return AVERROR(EINVAL);
     }
 
-    if (!stream_name)
-        stream_name = h->filename;
+    if (!stream_name) {
+        if (h->filename)
+            stream_name = h->filename;
+        else
+            stream_name = "Playback";
+    }
 
     ss.format = codec_id_to_pulse_format(st->codec->codec_id);
     ss.rate = st->codec->sample_rate;