From c62dfc498d240dfa09ec0365dbfb0f56e307ad43 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Tue, 14 Apr 2009 17:19:09 +0000 Subject: [PATCH] [#18517] Python scripts segfault on loading own error, EXPP_incr_ret from a macro was an implicit decloration in BGL.c For some reason this only crashed on 64bit linux To my defence the BGE makes so many warnings that they become usless, need to improve the situation here at some point. --- source/blender/python/api2_2x/BGL.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/source/blender/python/api2_2x/BGL.h b/source/blender/python/api2_2x/BGL.h index 89e56811b29..bad6330dd8d 100644 --- a/source/blender/python/api2_2x/BGL.h +++ b/source/blender/python/api2_2x/BGL.h @@ -304,7 +304,8 @@ typedef struct _Buffer { #define ret_def_void #define ret_set_void -#define ret_ret_void return EXPP_incr_ret(Py_None) +/* would use Py_RETURN_NONE - except for py 2.3 doesnt have it */ +#define ret_ret_void { Py_INCREF(Py_None); return Py_None; } #define ret_def_GLint int ret_int #define ret_set_GLint ret_int=