From 235011272a1d6fa6c8eb80fefa65a002b43b162e Mon Sep 17 00:00:00 2001 From: "fbarchard@google.com" Date: Tue, 28 May 2013 18:53:47 +0000 Subject: [PATCH] Fix warning on Windows about conversion from int to bool in convert util BUG=none TEST=none R=ryanpetrie@google.com Review URL: https://webrtc-codereview.appspot.com/1579004 git-svn-id: http://libyuv.googlecode.com/svn/trunk@702 16f28f9a-4ce2-e073-06de-1de4eb20be90 --- README.chromium | 2 +- include/libyuv/version.h | 2 +- util/convert.cc | 9 +++++---- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/README.chromium b/README.chromium index 927d07276..f54d6651e 100644 --- a/README.chromium +++ b/README.chromium @@ -1,6 +1,6 @@ Name: libyuv URL: http://code.google.com/p/libyuv/ -Version: 701 +Version: 702 License: BSD License File: LICENSE diff --git a/include/libyuv/version.h b/include/libyuv/version.h index c8cfa1d57..4e3ac746c 100644 --- a/include/libyuv/version.h +++ b/include/libyuv/version.h @@ -11,6 +11,6 @@ #ifndef INCLUDE_LIBYUV_VERSION_H_ // NOLINT #define INCLUDE_LIBYUV_VERSION_H_ -#define LIBYUV_VERSION 701 +#define LIBYUV_VERSION 702 #endif // INCLUDE_LIBYUV_VERSION_H_ NOLINT diff --git a/util/convert.cc b/util/convert.cc index ff3917228..4780bd4dc 100644 --- a/util/convert.cc +++ b/util/convert.cc @@ -203,8 +203,8 @@ int main(int argc, const char* argv[]) { } } - bool org_is_yuv = strstr(argv[fileindex_org], "_P420."); - bool org_is_argb = strstr(argv[fileindex_org], "_ARGB."); + bool org_is_yuv = strstr(argv[fileindex_org], "_P420.") != NULL; + bool org_is_argb = strstr(argv[fileindex_org], "_ARGB.") != NULL; if (!org_is_yuv && !org_is_argb) { fprintf(stderr, "Original format unknown %s\n", argv[fileindex_org]); exit(1); @@ -289,8 +289,9 @@ int main(int argc, const char* argv[]) { dst_width, dst_height, static_cast(filter)); } - bool rec_is_yuv = strstr(argv[fileindex_rec + cur_rec], "_P420."); - bool rec_is_argb = strstr(argv[fileindex_rec + cur_rec], "_ARGB."); + bool rec_is_yuv = strstr(argv[fileindex_rec + cur_rec], "_P420.") != NULL; + bool rec_is_argb = + strstr(argv[fileindex_rec + cur_rec], "_ARGB.") != NULL; if (!rec_is_yuv && !rec_is_argb) { fprintf(stderr, "Output format unknown %s\n", argv[fileindex_rec + cur_rec]);