Browse Source

lavd/pulse_audio_enc: add pointer checks

Signed-off-by: Lukasz Marek <lukasz.m.luki2@gmail.com>
tags/n2.3
Lukasz Marek 11 years ago
parent
commit
a1e5be5c1a
1 changed files with 4 additions and 2 deletions
  1. +4
    -2
      libavdevice/pulse_audio_enc.c

+ 4
- 2
libavdevice/pulse_audio_enc.c View File

@@ -692,8 +692,10 @@ static void pulse_get_output_timestamp(AVFormatContext *h, int stream, int64_t *
pa_threaded_mainloop_lock(s->mainloop);
pa_stream_get_latency(s->stream, &latency, &neg);
pa_threaded_mainloop_unlock(s->mainloop);
*wall = av_gettime();
*dts = s->timestamp - (neg ? -latency : latency);
if (wall)
*wall = av_gettime();
if (dts)
*dts = s->timestamp - (neg ? -latency : latency);
}

static int pulse_get_device_list(AVFormatContext *h, AVDeviceInfoList *device_list)


Loading…
Cancel
Save