From 60341c6efbdbf6487206503c0bd497a68bb2107f Mon Sep 17 00:00:00 2001 From: Fredrik Mellbin Date: Mon, 15 Oct 2012 15:54:21 +0000 Subject: [PATCH] more warnings --- include/VSHelper.h | 1 + src/core/vsapi.cpp | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/include/VSHelper.h b/include/VSHelper.h index 6cc4898..7c99f92 100644 --- a/include/VSHelper.h +++ b/include/VSHelper.h @@ -72,6 +72,7 @@ static inline int isSameFormat(const VSVideoInfo *v1, const VSVideoInfo *v2) { static inline int muldivRational(int64_t *num, int64_t *den, int64_t mul, int64_t div) { *num *= mul; *den *= div; + return 0; } // converts an int64 to int with saturation, useful to silence warnings when reading int properties among other things diff --git a/src/core/vsapi.cpp b/src/core/vsapi.cpp index ffac50e..19e28bb 100644 --- a/src/core/vsapi.cpp +++ b/src/core/vsapi.cpp @@ -222,7 +222,7 @@ static int getPropErrorCheck(const VSMap *props, const char *name, int index, in int c = propNumElements(props, name); - if (!err && c <= index || index < 0) + if ((!err && c <= index) || index < 0) err |= peIndex; if (err && !error) -- 2.11.4.GIT