| Summary: | Konqueror hangs on vwforum.vwforum.ro | ||
|---|---|---|---|
| Product: | [Applications] konqueror | Reporter: | András Manţia <amantia> |
| Component: | khtml | Assignee: | Konqueror Bugs <konqueror-bugs-null> |
| Status: | RESOLVED DUPLICATE | ||
| Severity: | normal | CC: | mail, maksim |
| Priority: | NOR | ||
| Version First Reported In: | unspecified | ||
| Target Milestone: | --- | ||
| Platform: | Compiled Sources | ||
| OS: | Linux | ||
| Latest Commit: | Version Fixed/Implemented In: | ||
| Sentry Crash Report: | |||
|
Description
András Manţia
2008-07-16 23:01:58 UTC
Skeleton of the stuck function --- blows away the collection cache:
{
var images = document.getElementsByTagName("IMG");
var _sw = screen.width * (parseInt(ipsclass.settings["resize_percent"]) / 100);
for (var i = 0; i < images.length; i++)
{
if (images[i].className == "linked-image")
{
images[i].id = "--ipb-img-resizer-" + _count;
images[i]._resized = 1;
images[i]._width = _width;
var div = document.createElement("div");
div.innerHTML = _img + " " + ipsclass.lang_build_string(ipb_global_lang["image_resized"], _percent, _width, _height);
div.className = "resized-linked-image";
div._src = images[i].src;
images[i].parentNode.insertBefore(div, images[i]);
}
}
}
}
This may or may not drop the constant factor:
--- ecma/kjs_dom.cpp (revision 831910)
+++ ecma/kjs_dom.cpp (working copy)
@@ -700,7 +700,18 @@
JSValue* DOMNodeList::indexGetter(ExecState *exec, unsigned index)
{
- return getDOMNode(exec, m_impl->item(index));
+ DOM::NodeImpl* n = m_impl->item(index);
+
+ if (n)
+ return getDOMNode(exec, n);
+
+ // Ouch. Not an index after all -- do backup behavior.
+ Identifier prop = Identifier::from(index);
+ n = getByName(prop);
+ if (n)
+ return getDOMNode(exec, n);
+
+ return getDirect(prop);
}
JSValue *DOMNodeList::nameGetter(ExecState *exec, JSObject*, const Identifier& name, const PropertySlot& slot)
@@ -746,8 +757,9 @@
if (proto && proto->hasProperty(exec, propertyName))
return false;
- //May be it's an index?
- if (getIndexSlot(this, *m_impl, propertyName, slot))
+ //May be it's an index? Do this w/o index check, since perhaps we're accessing low in
+ // an uncacheable collection
+ if (getIndexSlot(this, propertyName, slot))
return true;
//May be it's a name -- check by ID
One thing: you probably want to revert the patch I asked you to test, it has a bug that makes things very crashy. I am getting exactly the same freeze and backtrace with konqueror 4.1.0 on other forums too (like http://www.e-pcmag.gr/forum/ and http://forum.insanelymac.com/). I guess they might be all using the same forum software on the server side, as they all look similar. PS: bug 165668 seems to be a duplicate of this one... Fix committed *** This bug has been marked as a duplicate of bug 169844 *** |