[FFmpeg-cvslog] lavu/opt: prefer if(){}else{} over if()else{} construct

Stefano Sabatini git at videolan.org
Sat Nov 3 13:09:51 CET 2012


ffmpeg | branch: master | Stefano Sabatini <stefasab at gmail.com> | Fri Nov  2 15:55:42 2012 +0100| [ca11f6b240a1cb5e29267461ffa1037071c7bdb6] | committer: Stefano Sabatini

lavu/opt: prefer if(){}else{} over if()else{} construct

Improve consistency.

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=ca11f6b240a1cb5e29267461ffa1037071c7bdb6
---

 libavutil/opt.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavutil/opt.c b/libavutil/opt.c
index d65f7f3..140784e 100644
--- a/libavutil/opt.c
+++ b/libavutil/opt.c
@@ -265,9 +265,9 @@ int av_opt_set(void *obj, const char *name, const char *val, int search_flags)
             av_log(obj, AV_LOG_ERROR, "Unable to parse option value \"%s\" as image size\n", val);
         return ret;
     case AV_OPT_TYPE_PIXEL_FMT:
-        if (!val || !strcmp(val, "none"))
+        if (!val || !strcmp(val, "none")) {
             ret = AV_PIX_FMT_NONE;
-        else {
+        } else {
             ret = av_get_pix_fmt(val);
             if (ret == AV_PIX_FMT_NONE) {
                 char *tail;



More information about the ffmpeg-cvslog mailing list