[Expat-bugs] [ expat-Bugs-928113 ] XML_SetUnknownEncodingHandler()
return values are mixed.
SourceForge.net
noreply at sourceforge.net
Fri Apr 2 04:05:16 EST 2004
Bugs item #928113, was opened at 2004-04-02 13:05
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=110127&aid=928113&group_id=10127
Category: Documentation
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Maxim Petrovich Dementiev (maximdementiev)
Assigned to: Fred L. Drake, Jr. (fdrake)
Summary: XML_SetUnknownEncodingHandler() return values are mixed.
Initial Comment:
In documentation (reference.html) to expat-1.95.7
wrote:
"If the handler knows how to deal with an encoding
with the given name, it should fill in the info data
structure and return XML_STATUS_ERROR. Otherwise it
should return XML_STATUS_OK."
In expat.h:
enum XML_Status {
XML_STATUS_ERROR = 0, // false
#define XML_STATUS_ERROR XML_STATUS_ERROR
XML_STATUS_OK = 1 // not zero - ture
#define XML_STATUS_OK XML_STATUS_OK
};
In xmlparse.c:
if (unknownEncodingHandler(...)) {
// ... handler knows how to deal ...
... return XML_ERROR_NONE;
}
...
return XML_ERROR_UNKNOWN_ENCODING;
So right might be:
"If the handler knows how to deal with an encoding ...
return XML_STATUS_OK (not zero - ture). Otherwise it
should return XML_STATUS_ERROR (zero - false)."
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=110127&aid=928113&group_id=10127
More information about the Expat-bugs
mailing list