C99/C++11: replace deprecated finite() by isfinite().
[blender.git] / source / blender / python / generic / py_capi_utils.c
index dd32c913f7854805f43417fa914227bcf05a0f9f..7f13a7a4d94827888ac1825a36ed917d37c16814 100644 (file)
@@ -45,7 +45,7 @@
 
 #ifdef _WIN32
 #include "BLI_path_util.h"  /* BLI_setenv() */
-#include "BLI_math_base.h"  /* finite() */
+#include "BLI_math_base.h"  /* isfinite() */
 #endif
 
 /* array utility function */
@@ -1026,7 +1026,7 @@ bool PyC_RunString_AsNumber(const char *expr, double *value, const char *filenam
                if (val == -1 && PyErr_Occurred()) {
                        ok = false;
                }
-               else if (!finite(val)) {
+               else if (!isfinite(val)) {
                        *value = 0.0;
                }
                else {