[python-win32] Issue with win32evtlog.ReportEvent

Mark Hammond mhammond at skippinet.com.au
Fri Apr 22 06:12:09 CEST 2011

That is awesome - thanks very much.  It works as advertised (although 
there was one trivial problem in the patch when generating COM objects 
that I fixed.)

It works just fine with a py2k build, so all I need to do it integrate 
the changes Roger made for py3k into the mix and we are in a much better 
position :)

Again, thanks, and I'll check this in over the next week or so...



On 16/04/2011 2:56 AM, Amaury Forgeot d'Arc wrote:
> 2011/4/14 Mark Hammond<skippy.hammond at gmail.com>:
>> Sadly some hacks were made to SWIG to support some of the COM objects and
>> the source to those changes were lost many years ago - this needs to be
>> revisited before we can upgrade.  I haven't put much thought into that yet
>> but I'm sure something can be done...
> Here you are! Now you can comply with Swig's GPL license...
> I managed to hack an old version of SWIG and reproduce the same generated files:
> Start with the old swig 1.1p5:
> http://sourceforge.net/projects/swig/files/swig/1.1p5/
> and apply the attached patch.
> The differences with the files generated generated by the old swig.exe
> are small,
> and are all similar to this one: where you previously had::
>      static PyObject *_wrap_python_const_FILE_GENERIC_READ;
>      ...
>          _wrap_python_const_FILE_GENERIC_READ =
>          PyDict_SetItemString(d,"FILE_GENERIC_READ",
> _wrap_python_const_FILE_GENERIC_READ);
> You now have:
>          PyDict_SetItemString(d,"FILE_GENERIC_READ",
> PyInt_FromLong((long) FILE_GENERIC_READ));
> Which is a small improvement IMO.

More information about the python-win32 mailing list