mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 554230 - Crash [@ nsCopySupport::CanCopy][@ nsCopySupport::CanCopy(nsIDocument*) ]; r=jst
This commit is contained in:
parent
d6ce8dbd19
commit
ad8c4e400f
15
content/base/crashtests/554230-1.xhtml
Normal file
15
content/base/crashtests/554230-1.xhtml
Normal file
@ -0,0 +1,15 @@
|
||||
<html class="reftest-wait" xmlns="http://www.w3.org/1999/xhtml"><iframe contenteditable="true"></iframe><span></span><script style="display: none;" id="fuzz1" type="text/javascript">
|
||||
<![CDATA[
|
||||
|
||||
function boom()
|
||||
{
|
||||
document.getElementsByTagName("iframe")[0].focus();
|
||||
document.getElementsByTagName("span")[0].appendChild(document.createElementNS("http://www.w3.org/1999/xhtml", "div"));
|
||||
document.execCommand("selectAll", false, null);
|
||||
document.documentElement.removeAttribute("class");
|
||||
}
|
||||
|
||||
window.addEventListener("load", boom, false);
|
||||
|
||||
]]>
|
||||
</script></html>
|
@ -60,3 +60,4 @@ load 493281-2.html
|
||||
load 490760-1.xhtml
|
||||
load 494810-1.html
|
||||
load 529670.html
|
||||
load 554230-1.xhtml
|
||||
|
@ -629,6 +629,7 @@ nsCopySupport::CanCopy(nsIDocument* aDocument)
|
||||
|
||||
nsCOMPtr<nsISelection> sel;
|
||||
GetSelectionForCopy(aDocument, getter_AddRefs(sel));
|
||||
NS_ENSURE_TRUE(sel, PR_FALSE);
|
||||
|
||||
PRBool isCollapsed;
|
||||
sel->GetIsCollapsed(&isCollapsed);
|
||||
|
Loading…
Reference in New Issue
Block a user