From: Brian Aker Date: Fri, 1 Mar 2013 01:28:00 +0000 (-0800) Subject: Fix OSX/clang compiler warning. X-Git-Tag: 1.0.17~3^2~1^2 X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=673be386d6ae670d3c62051b10e7f57719338595;p=m6w6%2Flibmemcached Fix OSX/clang compiler warning. --- diff --git a/libhashkit/md5.cc b/libhashkit/md5.cc index cf68e3ca..ef867766 100644 --- a/libhashkit/md5.cc +++ b/libhashkit/md5.cc @@ -71,7 +71,13 @@ documentation and/or software. #include #include -#pragma GCC diagnostic ignored "-Wunsafe-loop-optimizations" +#define GCC_VERSION (__GNUC__ * 10000 \ + + __GNUC_MINOR__ * 100 \ + + __GNUC_PATCHLEVEL__) + +#if GCC_VERSION > 40600 +# pragma GCC diagnostic ignored "-Wunsafe-loop-optimizations" +#endif /* POINTER defines a generic pointer type */ typedef unsigned char *POINTER;