From: Mark H. <mha...@us...> - 2008-12-08 13:16:47
|
Update of /cvsroot/pywin32/pywin32/com/win32comext/internet/src In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv11284/com/win32comext/internet/src Modified Files: internet.cpp Log Message: py3k friendly: PYWIN_MODULE_* macros to help with module's init etc. Index: internet.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/com/win32comext/internet/src/internet.cpp,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** internet.cpp 2 Nov 2008 12:59:59 -0000 1.6 --- internet.cpp 8 Dec 2008 13:16:36 -0000 1.7 *************** *** 257,270 **** /* Module initialisation */ ! extern "C" __declspec(dllexport) void initinternet() { ! char *modName = "internet"; ! PyObject *oModule; ! // Create the module and add the functions ! oModule = Py_InitModule(modName, internet_methods); ! if (!oModule) /* Eeek - some serious error! */ ! return; ! PyObject *dict = PyModule_GetDict(oModule); ! if (!dict) return; /* Another serious error!*/ // Register all of our interfaces, gateways and IIDs. --- 257,264 ---- /* Module initialisation */ ! PYWIN_MODULE_INIT_FUNC(internet) { ! PYWIN_MODULE_INIT_PREPARE(internet, internet_methods, ! "A module, encapsulating the ActiveX Internet interfaces"); // Register all of our interfaces, gateways and IIDs. *************** *** 317,319 **** --- 311,315 ---- // ADD_CONSTANT(); // @const internet|| + + PYWIN_MODULE_INIT_RETURN_SUCCESS; } |