Fix memory leak: we have to SysFreeString BSTR that we receive as out parameters.
Fix memory leak: we have to SysFreeString BSTR that we receive as out
parameters.

Another memory leak.  COM objects in multithreaded appartments were
never Release()'d correctly.

Implement __setitem__ on COM interface pointer instances, which
manages the COM refcount correctly.

Merge in changes from the comtypes_events_branch:

comtypes.client.GetEvents returns a 'connection object', which will
UnAdvise the connection when deleted.  Remove the event specific
parameters from the comtypes.client object creation functions.

Be very careful in shutting down to avoid (ignored!) exceptions.

Changes in the COM shutdown code.

--HG--
extra : convert_revision : svn%3Aa2f44796-8cc0-49ac-b43f-6a96d556d52d/trunk%408

denfromufa/comtypes,denfromufa/comtypes,denfromufa/comtypes,denfromufa/comtypes,denfromufa/comtypes