Armin Rigo <[EMAIL PROTECTED]> writes:
> Hi Skip,
>
> On Wed, Jun 15, 2005 at 06:35:10AM -0700, [EMAIL PROTECTED] wrote:
>> Why this worked is a bit mystical. Perhaps it never gets freed because the
>> object just happens never to be DECREF'd (but that seems unlikely).
>> /* Add the Dialect type */
>> + Py_INCREF(&Dialect_Type);
>> if (PyModule_AddObject(module, "Dialect", (PyObject
>> *)&Dialect_Type))
>> return;
>
> Hum, you probably don't want to know, but it works just fine to forget
> a Py_INCREF before PyModule_AddObject() for the following reason:
No, it's more complicated than that, at least in an embedded
scenario (see bug #1220756).
I don't understand how thread._local differed from _cvs.Dialect,
though.
Cheers,
mwh
--
faassen: anyway, if nothing else flapping your arms running around
will at least give an impression of activity. :)
_______________________________________________
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com