Summary: | Accessing XMLHttpRequest()s .responseXML when the response XML contains a script tag with a src attribute crashes Konqueror | ||
---|---|---|---|
Product: | [Applications] konqueror | Reporter: | Frederik Reiss <frederik.reiss> |
Component: | khtml xml | Assignee: | Konqueror Developers <konq-bugs> |
Status: | RESOLVED WORKSFORME | ||
Severity: | crash | CC: | finex, james, justin.zobel, maksim |
Priority: | NOR | ||
Version First Reported In: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Debian testing | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
Frederik Reiss
2006-03-12 13:58:56 UTC
hmm, this suggests some bad stuff about namespace handling :-( SVN commit 517910 by orlovich: Properly handle script namespace in XML parser BUG:123490 M +2 -2 xml_tokenizer.cpp --- branches/KDE/3.5/kdelibs/khtml/xml/xml_tokenizer.cpp #517909:517910 @@ -157,7 +157,7 @@ return false; } - if (newElement->id() == ID_SCRIPT) + if (newElement->id() == makeId(xhtmlNamespace, ID_SCRIPT)) static_cast<HTMLScriptElementImpl *>(newElement)->setCreatedByParser(true); //this is tricky. in general the node doesn't have to attach to the one it's in. as far @@ -491,7 +491,7 @@ // Recursively go through the entire document tree, looking for html <script> tags. For each of these // that is found, add it to the m_scripts list from which they will be executed - if (n->id() == ID_SCRIPT) { + if (n->id() == makeId(xhtmlNamespace, ID_SCRIPT)) { m_scripts.append(static_cast<HTMLScriptElementImpl*>(n)); } hmm, wrong :-(. This sucks. SVN commit 517915 by orlovich: Revert. Need to sort out the no namespace vs. xhtml namespace mess to fix this: CCBUG:123490 M +2 -2 xml_tokenizer.cpp --- branches/KDE/3.5/kdelibs/khtml/xml/xml_tokenizer.cpp #517914:517915 @@ -157,7 +157,7 @@ return false; } - if (newElement->id() == makeId(xhtmlNamespace, ID_SCRIPT)) + if (newElement->id() == ID_SCRIPT) static_cast<HTMLScriptElementImpl *>(newElement)->setCreatedByParser(true); //this is tricky. in general the node doesn't have to attach to the one it's in. as far @@ -491,7 +491,7 @@ // Recursively go through the entire document tree, looking for html <script> tags. For each of these // that is found, add it to the m_scripts list from which they will be executed - if (n->id() == makeId(xhtmlNamespace, ID_SCRIPT)) { + if (n->id() == ID_SCRIPT) { m_scripts.append(static_cast<HTMLScriptElementImpl*>(n)); } Konqueror 4.0.3 produces no crash. Bug appears to be fixed. I put an online copy of this for ease of testing: http://nixeagle.org/kdebugs/123490/crash.html - when the page opens, just click the link. You should get a popup, if not I presume you will get a lovely crash. Using Gentoo Linux ~x86 (testing in gentoo lingo). KDE 4.0.3 and the majority of packages compiled using gcc 4.3.0. Cannot reproduce the crash on 3.5.9 AND konqueror trunk (revision 800924). The bug has been fixed :-) No, it hasn't been. It just luckily doesn't crash. Thank you for the report, Frederik. As it has been a while since this was reported, can you please test and confirm if this issue is still occurring or if this bug report can be marked as resolved. I have set the bug status to "needsinfo" pending your response, please change back to "reported" or "resolved/worksforme" when you respond, thank you. Dear Bug Submitter, This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information as soon as possible and set the bug status as REPORTED. Due to regular bug tracker maintenance, if the bug is still in NEEDSINFO status with no change in 30 days the bug will be closed as RESOLVED > WORKSFORME due to lack of needed information. For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging If you have already provided the requested information, please mark the bug as REPORTED so that the KDE team knows that the bug is ready to be confirmed. Thank you for helping us make KDE software even better for everyone! This bug has been in NEEDSINFO status with no change for at least 30 days. The bug is now closed as RESOLVED > WORKSFORME due to lack of needed information. For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging Thank you for helping us make KDE software even better for everyone! |