Closed GoogleCodeExporter closed 8 years ago
The fix to this has taken between 5 and 10 hours, as I chased my tail trying to
understand what the problem was (first) and secondly how to convince the SAX
parser to apply the encoding. It transpired that the way we called the SAX
parser was subtley different in DaisyParser.java (which didn't seem to apply
the encoding) and SmilParser.java (which worked as desired). The hint (which I
noticed in the final hour of debugging) was that ncc.html files in unsupported
encodings (e.g. windows-1252) did NOT throw a SAX Parser Exception, while
SmilFiles with the same encoding did throw this exception. Essentially I
modified the code in DaisyParser (and the code that calls
parseNccContents(...)) to match the way we create the InputSource in
SmilParser.java. That did the trick.
The code is still ugly and needs cleaning up.
Original comment by julianharty
on 26 Dec 2010 at 8:18
Original issue reported on code.google.com by
julianharty
on 26 Dec 2010 at 8:08