thumbnail: fix error code in case of invalid args.
authorClément Bœsch <ubitux@gmail.com>
Tue, 27 Dec 2011 10:15:21 +0000 (11:15 +0100)
committerClément Bœsch <ubitux@gmail.com>
Tue, 27 Dec 2011 10:15:21 +0000 (11:15 +0100)
libavfilter/vf_thumbnail.c

index b2f1e94..4b1b38b 100644 (file)
@@ -54,7 +54,7 @@ static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque)
             thumb->n_frames = 0;
             av_log(ctx, AV_LOG_ERROR,
                    "Invalid number of frames specified (minimum is 2).\n");
-            return AVERROR(ENOMEM);
+            return AVERROR(EINVAL);
         }
     }
     thumb->frames = av_calloc(thumb->n_frames, sizeof(*thumb->frames));