pulsesink: Don't dereference NULL pointers

pa_stream_get_timing_info() can return NULL.

Fixes bug #595220.
This commit is contained in:
David Henningsson 2009-09-15 10:01:54 +02:00 committed by Sebastian Dröge
parent ccda761562
commit bb787f1030

View file

@ -545,6 +545,10 @@ gst_pulsering_stream_latency_cb (pa_stream * s, void *userdata)
pbuf = GST_PULSERING_BUFFER_CAST (userdata); pbuf = GST_PULSERING_BUFFER_CAST (userdata);
psink = GST_PULSESINK_CAST (GST_OBJECT_PARENT (pbuf)); psink = GST_PULSESINK_CAST (GST_OBJECT_PARENT (pbuf));
if (!info) {
GST_LOG_OBJECT (psink, "latency update (information unknown)");
return;
}
#if HAVE_PULSE_0_9_11 #if HAVE_PULSE_0_9_11
sink_usec = info->configured_sink_usec; sink_usec = info->configured_sink_usec;
#else #else