From: John F. Fay Date: Mon, 30 Jan 2012 03:34:22 +0000 (+0000) Subject: Fixing a bug I introduced into the "...ATEXIT" hack X-Git-Url: http://git.mutantstargoat.com/user/nuclear/?a=commitdiff_plain;h=4c83751ce90624de7cb03a04f389300a2318e61f;p=freeglut Fixing a bug I introduced into the "...ATEXIT" hack git-svn-id: svn+ssh://svn.code.sf.net/p/freeglut/code/trunk/freeglut/freeglut@1031 7f0cb862-5218-0410-a997-914c9d46530a --- diff --git a/src/mswin/freeglut_init_mswin.c b/src/mswin/freeglut_init_mswin.c index 568170e..d5c94e5 100644 --- a/src/mswin/freeglut_init_mswin.c +++ b/src/mswin/freeglut_init_mswin.c @@ -25,6 +25,7 @@ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +#define FREEGLUT_BUILDING_LIB #include #include "../Common/freeglut_internal.h" @@ -331,7 +332,6 @@ int XParseGeometry ( /* -- PLATFORM-SPECIFIC INTERFACE FUNCTION -------------------------------------------------- */ - void (__cdecl *__glutExitFunc)( int return_value ) = NULL; void FGAPIENTRY __glutInitWithExit( int *pargc, char **argv, void (__cdecl *exit_function)(int) ) diff --git a/src/mswin/freeglut_menu_mswin.c b/src/mswin/freeglut_menu_mswin.c index 5731cef..e280624 100644 --- a/src/mswin/freeglut_menu_mswin.c +++ b/src/mswin/freeglut_menu_mswin.c @@ -25,6 +25,7 @@ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +#define FREEGLUT_BUILDING_LIB #include #include "../Common/freeglut_internal.h" @@ -39,7 +40,6 @@ GLvoid fgPlatformGetGameModeVMaxExtent( SFG_Window* window, int* x, int* y ) /* -- PLATFORM-SPECIFIC INTERFACE FUNCTION -------------------------------------------------- */ - int FGAPIENTRY __glutCreateMenuWithExit( void(* callback)( int ), void (__cdecl *exit_function)(int) ) { __glutExitFunc = exit_function; diff --git a/src/mswin/freeglut_window_mswin.c b/src/mswin/freeglut_window_mswin.c index cd0400a..d4c5fd7 100644 --- a/src/mswin/freeglut_window_mswin.c +++ b/src/mswin/freeglut_window_mswin.c @@ -25,6 +25,7 @@ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +#define FREEGLUT_BUILDING_LIB #include #include "../Common/freeglut_internal.h" @@ -1080,7 +1081,6 @@ void fgPlatformGlutFullScreenToggle( SFG_Window *win ) /* -- PLATFORM-SPECIFIC INTERFACE FUNCTION -------------------------------------------------- */ - int FGAPIENTRY __glutCreateWindowWithExit( const char *title, void (__cdecl *exit_function)(int) ) { __glutExitFunc = exit_function;