]> git.sesse.net Git - ffmpeg/commitdiff
avformat/westwood_aud: replace != 0 error check by <0
authorMichael Niedermayer <michaelni@gmx.at>
Sat, 20 Dec 2014 00:51:16 +0000 (01:51 +0100)
committerMichael Niedermayer <michaelni@gmx.at>
Sat, 20 Dec 2014 00:51:16 +0000 (01:51 +0100)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavformat/westwood_aud.c

index 52868752dceaba00a42a67043be39081ffc49fd7..6d8dbdbd351d8fcfc3c18b67177b3fabce408ce2 100644 (file)
@@ -151,7 +151,7 @@ static int wsaud_read_packet(AVFormatContext *s,
            Specifically, this is needed to signal when a packet should be
            decoding as raw 8-bit pcm or variable-size ADPCM. */
         int out_size = AV_RL16(&preamble[2]);
-        if ((ret = av_new_packet(pkt, chunk_size + 4)))
+        if ((ret = av_new_packet(pkt, chunk_size + 4)) < 0)
             return ret;
         if ((ret = avio_read(pb, &pkt->data[4], chunk_size)) != chunk_size)
             return ret < 0 ? ret : AVERROR(EIO);