From: <mha...@us...> - 2011-10-03 23:12:45
|
Revision: 689 http://py2exe.svn.sourceforge.net/py2exe/?rev=689&view=rev Author: mhammond Date: 2011-10-03 23:12:39 +0000 (Mon, 03 Oct 2011) Log Message: ----------- ensure sys.frozendllhandle is valid in 64bit builds Modified Paths: -------------- trunk/py2exe/source/run_ctypes_dll.c trunk/py2exe/source/run_dll.c trunk/py2exe/source/run_isapi.c Modified: trunk/py2exe/source/run_ctypes_dll.c =================================================================== --- trunk/py2exe/source/run_ctypes_dll.c 2010-04-26 07:22:49 UTC (rev 688) +++ trunk/py2exe/source/run_ctypes_dll.c 2011-10-03 23:12:39 UTC (rev 689) @@ -138,7 +138,7 @@ // a little DLL magic. Set sys.frozen='dll' init_with_instance(gInstance, "dll"); init_memimporter(); - frozen = PyInt_FromLong((LONG)gInstance); + frozen = PyLong_FromVoidPtr(gInstance); if (frozen) { PySys_SetObject("frozendllhandle", frozen); Py_DECREF(frozen); Modified: trunk/py2exe/source/run_dll.c =================================================================== --- trunk/py2exe/source/run_dll.c 2010-04-26 07:22:49 UTC (rev 688) +++ trunk/py2exe/source/run_dll.c 2011-10-03 23:12:39 UTC (rev 689) @@ -201,7 +201,7 @@ // a little DLL magic. Set sys.frozen='dll' init_with_instance(gInstance, "dll"); init_memimporter(); - frozen = PyInt_FromLong((LONG)gInstance); + frozen = PyLong_FromVoidPtr(gInstance); if (frozen) { PySys_SetObject("frozendllhandle", frozen); Py_DECREF(frozen); Modified: trunk/py2exe/source/run_isapi.c =================================================================== --- trunk/py2exe/source/run_isapi.c 2010-04-26 07:22:49 UTC (rev 688) +++ trunk/py2exe/source/run_isapi.c 2011-10-03 23:12:39 UTC (rev 689) @@ -185,7 +185,7 @@ goto done; } init_memimporter(); - frozen = PyInt_FromLong((LONG)gInstance); + frozen = PyLong_FromVoidPtr(gInstance); if (frozen) { PySys_SetObject("frozendllhandle", frozen); Py_DECREF(frozen); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |