RESOLVED WONTFIX 10341
SVGs fail to render intermittently (on reload)
https://bugs.webkit.org/show_bug.cgi?id=10341
Summary SVGs fail to render intermittently (on reload)
Eric Seidel (no email)
Reported 2006-08-10 19:17:40 PDT
REGRESSION: All embedded SVGs fail to render intermittently (on reload)They fail out due to a libxml error. I've seen this error before, and I believe it happens when you call switchEncoding when you don't actuallly have any data to write. error on line 1 at column 1: switching encoding : no input
Attachments
Eric Seidel (no email)
Comment 1 2006-09-12 22:32:02 PDT
Wow, strange enough this is still an issue. :( I'm testing with r16339.
Eric Seidel (no email)
Comment 2 2007-01-15 01:33:15 PST
This is still a (really bad!) problem on TOT. Although since WebKit has never officially shipped SVG, I'm not sure this can be a P1 regression.
Stephanie Lewis
Comment 3 2007-01-27 19:53:38 PST
Maciej Stachowiak
Comment 4 2007-02-07 04:51:54 PST
Removing regression tag and downgrading to P2 per Eric's comments.
Eric Seidel (no email)
Comment 5 2007-06-12 11:49:15 PDT
*** Bug 13188 has been marked as a duplicate of this bug. ***
Eric Seidel (no email)
Comment 6 2008-11-21 14:33:40 PST
I'm seeing this on http://www.carto.net/papers/svg/samples/matrix.svg just now as well.
Eric Seidel (no email)
Comment 7 2008-11-21 14:35:25 PST
I suspect this is related to the encoding switching we do to work around another libxml bug: void XMLTokenizer::doWrite(const String& parseString) { if (!m_context) initializeParserContext(); // libXML throws an error if you try to switch the encoding for an empty string. if (parseString.length()) { // Hack around libxml2's lack of encoding overide support by manually // resetting the encoding to UTF-16 before every chunk. Otherwise libxml // will detect <?xml version="1.0" encoding="<encoding name>"?> blocks // and switch encodings, causing the parse to fail. const UChar BOM = 0xFEFF; const unsigned char BOMHighByte = *reinterpret_cast<const unsigned char*>(&BOM); xmlSwitchEncoding(m_context, BOMHighByte == 0xFF ? XML_CHAR_ENCODING_UTF16LE : XML_CHAR_ENCODING_UTF16BE); xmlParseChunk(m_context, reinterpret_cast<const char*>(parseString.characters()), sizeof(UChar) * parseString.length(), 0); } if (m_doc->decoder() && m_doc->decoder()->sawError()) { // If the decoder saw an error, report it as fatal (stops parsing) handleError(fatal, "Encoding error", lineNumber(), columnNumber()); } return; }
Eric Seidel (no email)
Comment 8 2008-11-21 14:36:39 PST
Today I'm using: Version 4.0 (5528.1) ProductName: Mac OS X ProductVersion: 10.5.5 BuildVersion: 9F33
Dirk Schulze
Comment 9 2011-05-18 10:20:04 PDT
I don't see problems on reload. But indeed it does not look correct. Like eric wrote, this is a bug with libxml and just occurs on MacOS right now. This should work, once Mac OS X has a newer version of libxml. I mark this as WONTFIX, since this is not a problem of WebKit. At least we don't want to add hacks as workaround for bugs in libxml.
Note You need to log in before you can comment on or make changes to this bug.