]> git.sesse.net Git - ffmpeg/commitdiff
Fix various if parenthesis misplacements.
authorClément Bœsch <ubitux@gmail.com>
Mon, 21 Nov 2011 06:50:03 +0000 (07:50 +0100)
committerClément Bœsch <ubitux@gmail.com>
Mon, 21 Nov 2011 18:35:33 +0000 (19:35 +0100)
doc/examples/filtering.c
libavcodec/alsdec.c
libavdevice/v4l2.c
libavfilter/vf_drawtext.c
libavfilter/vf_fifo.c
libavformat/wav.c

index 3ed6aa3a54cc06c30e9025349da6218b64f25bb3..06e513026e31b148f79cc1c22fe9017b4ef3732b 100644 (file)
@@ -173,7 +173,7 @@ int main(int argc, char **argv)
     av_register_all();
     avfilter_register_all();
 
-    if ((ret = open_input_file(argv[1]) < 0))
+    if ((ret = open_input_file(argv[1])) < 0)
         goto end;
     if ((ret = init_filters(filter_descr)) < 0)
         goto end;
index fdcbd3fb4447a212de0dbe7329eee8a25d147edf..fc98970bd7479574f7967972693cabcc21a63009 100644 (file)
@@ -1442,7 +1442,7 @@ static int decode_frame(AVCodecContext *avctx,
         ctx->cur_frame_length = sconf->frame_length;
 
     // decode the frame data
-    if ((invalid_frame = read_frame_data(ctx, ra_frame) < 0))
+    if ((invalid_frame = read_frame_data(ctx, ra_frame)) < 0)
         av_log(ctx->avctx, AV_LOG_WARNING,
                "Reading frame data failed. Skipping RA unit.\n");
 
index 08ee201c79d8a7d61bdf89bc48aa9fe8e9c7ff47..07d3cb445db213a5529055e17c1be13922a662f2 100644 (file)
@@ -634,11 +634,11 @@ static int v4l2_read_header(AVFormatContext *s1, AVFormatParameters *ap)
         res = AVERROR(EIO);
         goto out;
     }
-    if ((res = av_image_check_size(s->width, s->height, 0, s1) < 0))
+    if ((res = av_image_check_size(s->width, s->height, 0, s1)) < 0)
         goto out;
     s->frame_format = desired_format;
 
-    if ((res = v4l2_set_parameters(s1, ap) < 0))
+    if ((res = v4l2_set_parameters(s1, ap)) < 0)
         goto out;
 
     st->codec->pix_fmt = fmt_v4l2ff(desired_format, codec_id);
index 7d4476f849d8334a0abd65eb48b0ada7c021ce8d..43d39c0ad26d276693c6118ed25a1cb910d39976 100644 (file)
@@ -359,7 +359,7 @@ static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque)
     load_glyph(ctx, NULL, 0);
 
     /* set the tabsize in pixels */
-    if ((err = load_glyph(ctx, &glyph, ' ') < 0)) {
+    if ((err = load_glyph(ctx, &glyph, ' ')) < 0) {
         av_log(ctx, AV_LOG_ERROR, "Could not set tabsize.\n");
         return err;
     }
index 46e93730ef02a73c9924077a79e4bccdb58085bc..06018116ed4099c27728ad3d1bb5baac817a7605 100644 (file)
@@ -76,7 +76,7 @@ static int request_frame(AVFilterLink *outlink)
     int ret;
 
     if (!fifo->root.next) {
-        if ((ret = avfilter_request_frame(outlink->src->inputs[0]) < 0))
+        if ((ret = avfilter_request_frame(outlink->src->inputs[0])) < 0)
             return ret;
     }
 
index 096f706c37bb0f35eeb9316a36fcf15d10535274..22914c9ad530b98aa169b857ec0b5131035ab85f 100644 (file)
@@ -442,7 +442,7 @@ static int wav_read_header(AVFormatContext *s,
         switch (tag) {
         case MKTAG('f', 'm', 't', ' '):
             /* only parse the first 'fmt ' tag found */
-            if (!got_fmt && (ret = wav_parse_fmt_tag(s, size, &st) < 0)) {
+            if (!got_fmt && (ret = wav_parse_fmt_tag(s, size, &st)) < 0) {
                 return ret;
             } else if (got_fmt)
                 av_log(s, AV_LOG_WARNING, "found more than one 'fmt ' tag\n");