From: <fwi...@us...> - 2009-08-10 17:15:53
|
Revision: 6643 http://jython.svn.sourceforge.net/jython/?rev=6643&view=rev Author: fwierzbicki Date: 2009-08-10 17:15:48 +0000 (Mon, 10 Aug 2009) Log Message: ----------- reindent. Modified Paths: -------------- trunk/jython/Lib/xml/parsers/expat.py Modified: trunk/jython/Lib/xml/parsers/expat.py =================================================================== --- trunk/jython/Lib/xml/parsers/expat.py 2009-08-10 17:14:52 UTC (rev 6642) +++ trunk/jython/Lib/xml/parsers/expat.py 2009-08-10 17:15:48 UTC (rev 6643) @@ -171,18 +171,18 @@ returns_unicode = property(_get_returns_unicode, _set_returns_unicode) def _expat_error(self, sax_error): - sax_message = sax_error.getMessage() - pattern = 'The entity ".*" was referenced, but not declared\.' - if re.match(pattern, sax_message): - expat_message = "undefined entity: line %s, column %s" % \ - (self.ErrorLineNumber, self.ErrorColumnNumber) - else: - expat_message = sax_message - error = ExpatError(expat_message) - error.lineno = self.ErrorLineNumber - error.offset = self.ErrorColumnNumber - error.code = self.ErrorCode - return error + sax_message = sax_error.getMessage() + pattern = 'The entity ".*" was referenced, but not declared\.' + if re.match(pattern, sax_message): + expat_message = "undefined entity: line %s, column %s" % \ + (self.ErrorLineNumber, self.ErrorColumnNumber) + else: + expat_message = sax_message + error = ExpatError(expat_message) + error.lineno = self.ErrorLineNumber + error.offset = self.ErrorColumnNumber + error.code = self.ErrorCode + return error def Parse(self, data, isfinal=False): # The 'data' argument should be an encoded text: a str instance that This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |