Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLukasz Marek <lukasz.m.luki@gmail.com>2013-10-19 01:41:19 +0400
committerStefano Sabatini <stefasab@gmail.com>2013-10-19 01:59:27 +0400
commitf5695926235c9b2a60af07b21c2d6f1db990cc2a (patch)
treed037ddd4a4d0291785daf48d7fc8b23acffc66b0
parentf6b56b1f26a1e40a47d85d24b42cd5475cd3b04f (diff)
lavd/pulse_audio_enc: fix error check
Error check should be done by checking negative value, not non-zero. Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com> Signed-off-by: Stefano Sabatini <stefasab@gmail.com>
-rw-r--r--libavdevice/pulse_audio_enc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavdevice/pulse_audio_enc.c b/libavdevice/pulse_audio_enc.c
index 25caa65a95..0a3aa1ad09 100644
--- a/libavdevice/pulse_audio_enc.c
+++ b/libavdevice/pulse_audio_enc.c
@@ -105,7 +105,7 @@ static int pulse_write_packet(AVFormatContext *h, AVPacket *pkt)
if (s->stream_index != pkt->stream_index)
return 0;
- if ((error = pa_simple_write(s->pa, buf, size, &error))) {
+ if (pa_simple_write(s->pa, buf, size, &error) < 0) {
av_log(s, AV_LOG_ERROR, "pa_simple_write failed: %s\n", pa_strerror(error));
return AVERROR(EIO);
}