diff options
author | Campbell Barton <ideasman42@gmail.com> | 2011-05-22 08:25:31 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2011-05-22 08:25:31 +0400 |
commit | 6e39d908a983cb883a58f1d9fdc2defac572a29c (patch) | |
tree | f953658d3e47440c6f485b6f986d9d12b2ba3bee /source/blender | |
parent | b1ddf90239153dfea1dc5971b668a30f7cd0c93b (diff) |
quiet compiler warnings for -Wundef
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/blenlib/BLI_path_util.h | 2 | ||||
-rw-r--r-- | source/blender/blenlib/intern/math_base.c | 2 | ||||
-rw-r--r-- | source/blender/imbuf/intern/IMB_anim.h | 2 | ||||
-rw-r--r-- | source/blender/imbuf/intern/md5.h | 2 | ||||
-rw-r--r-- | source/blender/python/generic/mathutils_Matrix.c | 4 |
5 files changed, 6 insertions, 6 deletions
diff --git a/source/blender/blenlib/BLI_path_util.h b/source/blender/blenlib/BLI_path_util.h index dd4ae781832..360cd1ea9ab 100644 --- a/source/blender/blenlib/BLI_path_util.h +++ b/source/blender/blenlib/BLI_path_util.h @@ -86,7 +86,7 @@ char *BLI_get_folder_version(const int id, const int ver, const int do_check); #ifdef WIN32 #define BLENDER_USER_FORMAT "%s\\Blender Foundation\\Blender\\%s" #define BLENDER_SYSTEM_FORMAT "%s\\Blender Foundation\\Blender\\%s" -#elif __APPLE__ +#elif defined(__APPLE__) #define BLENDER_USER_FORMAT "%s/Blender/%s" #define BLENDER_SYSTEM_FORMAT "%s/Blender/%s" #else diff --git a/source/blender/blenlib/intern/math_base.c b/source/blender/blenlib/intern/math_base.c index 0e122a23faa..8ad93495f6d 100644 --- a/source/blender/blenlib/intern/math_base.c +++ b/source/blender/blenlib/intern/math_base.c @@ -34,7 +34,7 @@ #include "BLI_math.h" /* WARNING: MSVC compiling hack for double_round() */ -#if (WIN32 || WIN64) && !(FREE_WINDOWS) +#if (defined(WIN32) || defined(WIN64)) && !(defined(FREE_WINDOWS)) /* from python 3.1 pymath.c */ double copysign(double x, double y) diff --git a/source/blender/imbuf/intern/IMB_anim.h b/source/blender/imbuf/intern/IMB_anim.h index 4804d363628..fba0772dd93 100644 --- a/source/blender/imbuf/intern/IMB_anim.h +++ b/source/blender/imbuf/intern/IMB_anim.h @@ -107,7 +107,7 @@ #define SWAP_S(x) (((x << 8) & 0xff00) | ((x >> 8) & 0xff)) /* more endianness... should move to a separate file... */ -#if defined(__sgi) || defined (__sparc) || (__sparc__) || defined (__PPC__) || defined (__ppc__) || defined (__hppa__) || defined (__BIG_ENDIAN__) +#if defined(__sgi) || defined (__sparc) || defined (__sparc__) || defined (__PPC__) || defined (__ppc__) || defined (__hppa__) || defined (__BIG_ENDIAN__) #define GET_ID GET_BIG_LONG #define LITTLE_LONG SWAP_LONG #else diff --git a/source/blender/imbuf/intern/md5.h b/source/blender/imbuf/intern/md5.h index 5fc1f80216f..79c480d8152 100644 --- a/source/blender/imbuf/intern/md5.h +++ b/source/blender/imbuf/intern/md5.h @@ -24,7 +24,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. #include <stdio.h> -#if defined HAVE_LIMITS_H || _LIBC +#if defined HAVE_LIMITS_H || defined _LIBC # include <limits.h> #endif diff --git a/source/blender/python/generic/mathutils_Matrix.c b/source/blender/python/generic/mathutils_Matrix.c index 2b9de49bf3f..80f6ddf2d30 100644 --- a/source/blender/python/generic/mathutils_Matrix.c +++ b/source/blender/python/generic/mathutils_Matrix.c @@ -132,12 +132,12 @@ static PyObject *Matrix_new(PyTypeObject *type, PyObject *args, PyObject *kwds) const unsigned short row_size= PySequence_Size(arg); /* -1 is an error, size checks will accunt for this */ - if(IN_RANGE_INCL(row_size, 2, 4)) { + if(row_size >= 2 && row_size <= 4) { PyObject *item= PySequence_GetItem(arg, 0); const unsigned short col_size= PySequence_Size(item); Py_XDECREF(item); - if(IN_RANGE_INCL(col_size, 2, 4)) { + if(col_size >= 2 && col_size <= 4) { /* sane row & col size, new matrix and assign as slice */ PyObject *matrix= newMatrixObject(NULL, row_size, col_size, Py_NEW, type); if(Matrix_ass_slice((MatrixObject *)matrix, 0, INT_MAX, arg) == 0) { |