Thomas Heller schrieb: > Michael Curran schrieb: >> Perhaps you can use None, I'm not sure. However, I used c_voidp, not >> c_void_p. >> c_voidp as far as I am aware means void parameter, not void pointer. >> c_voidp can be used in ctypes function declarations for the return type >> when it is void. >> >> c_void_p is void pointer. > > c_voidp and c_void_p is actually the very same type; which means a void > pointer. > If a function or method returns nothing, 'void func(...)' in C, than 'None' > should be used for the .restype attribute. > > So the correct comtypes definition is: >>>> COMMETHOD([], None, 'ReleaseTLibAttr', >>>> (['in'], POINTER(TLIBATTR))) >>>> ] > > > Thanks for finding it. I will correct it in svn asap.
This is now fixed in SVN. If anyone needs a new release please let me know. Changes since 0.6 so far are only these: 2009-03-17 Thomas Heller <thel...@python.net> * Fixed the return type of ITypeLib::ReleaseTLibAttr, which is documented wrongly in MSDN. The return type is void, not HRESULT. Reported to cause crashes on Windows 7. 2009-01-29 Thomas Heller <thel...@python.net> * Restore compatibility with Python 2.3. * comtypes\client\_code_cache.py: Add missing 'import types' in comtypes\client\_code_cache.py. -- Thanks, Thomas ------------------------------------------------------------------------------ Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are powering Web 2.0 with engaging, cross-platform capabilities. Quickly and easily build your RIAs with Flex Builder, the Eclipse(TM)based development software that enables intelligent coding and step-through debugging. Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com _______________________________________________ comtypes-users mailing list comtypes-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/comtypes-users