homepage

This issue tracker has been migrated to GitHub , and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author lemburg
Recipients Arfrever, amaury.forgeotdarc, belopolsky, ezio.melotti, jafo, lemburg, loewis, ronaldoussoren, vstinner
Date 2010年12月07日.17:44:20
SpamBayes Score 5.2980953e-12
Marked as misclassified No
Message-id <4CFE726F.3080506@egenix.com>
In-reply-to <1291742366.02.0.161646897124.issue6697@psf.upfronthosting.co.za>
Content
Alexander Belopolsky wrote:
> 
> Alexander Belopolsky <belopolsky@users.sourceforge.net> added the comment:
> 
> I am attaching a revised version of the patch which also includes some tests. Interestingly, the issue in syslog module is a regression from 3.1 introduced in r80401. Although it is not a crasher, I don't think it was intentional because although openlog() is happy to accept NULL for indent, the error from _PyUnicode_AsString() would have to be cleared if the intent was to ignore undecodable indent.
Some notes:
* Rather than just patching in error handling code, please consider
removing use of those APIs and replace their calls with something
more appropriate, e.g. using a parser API.
* When ignoring errors from the API, you have to clear the exception.
This is missing in a couple of places in the patch, e.g. in pyexpat.c
* Please also remove hacks like these:
+#define CMP PyUnicode_CompareWithASCIIString
+ if (CMP(nameobj, "entity") == 0)
+ res = self->entity;
+ else if (CMP(nameobj, "target") == 0)
+ res = self->target;
+ else if (CMP(nameobj, "version") == 0) {
+ return PyUnicode_FromFormat(
+ "Expat %d.%d.%d", XML_MAJOR_VERSION,
 XML_MINOR_VERSION, XML_MICRO_VERSION);
History
Date User Action Args
2010年12月07日 17:44:24lemburgsetrecipients: + lemburg, loewis, jafo, ronaldoussoren, amaury.forgeotdarc, belopolsky, vstinner, ezio.melotti, Arfrever
2010年12月07日 17:44:20lemburglinkissue6697 messages
2010年12月07日 17:44:20lemburgcreate

AltStyle によって変換されたページ (->オリジナル) /