avcodec/jpeg2000dec: Use <0 instead of != 0 for error checking
authorMichael Niedermayer <michaelni@gmx.at>
Mon, 15 Jun 2015 00:19:48 +0000 (02:19 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Mon, 15 Jun 2015 00:19:48 +0000 (02:19 +0200)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavcodec/jpeg2000dec.c

index 7b1034e..a4f5c8c 100644 (file)
@@ -1788,11 +1788,11 @@ static int jpeg2000_read_bitstream_packets(Jpeg2000DecoderContext *s)
     for (tileno = 0; tileno < s->numXtiles * s->numYtiles; tileno++) {
         Jpeg2000Tile *tile = s->tile + tileno;
 
-        if (ret = init_tile(s, tileno))
+        if ((ret = init_tile(s, tileno)) < 0)
             return ret;
 
         s->g = tile->tile_part[0].tpg;
-        if (ret = jpeg2000_decode_packets(s, tile))
+        if ((ret = jpeg2000_decode_packets(s, tile)) < 0)
             return ret;
     }