blob: a693820a036fe8cc6bf9a2dc59150f1db016361b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Strict//EN">
<html>
<head>
<meta HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=UTF-8">
<title>Weee!</title>
<script>
window.onload = function() {
if (window.testRunner)
window.testRunner.dumpAsText();
var meths = [
document.lookupNamespaceURI,
document.isDefaultNamespace,
function(node) { this.body = node },
document.lookupPrefix
];
var node = document.createElement('b');
// Empty the document
while (document.firstChild)
document.removeChild(document.firstChild);
for (var i = 0, il = meths.length; i < il; ++i) {
try {
// Some expect nodes, some expect strings, but our nodes will get
// toString'd so we should be ok on both.
meths[i].call(document, node, node, node);
} catch(e) { }
}
document.open();
document.write('PASS');
document.close();
};
</script>
</head>
<body>
<p>Test for <a href="http://bugs.webkit.org/show_bug.cgi?id=19470">bug 19470</a>:
Null pointer dereferences on a document with no documentElement.</p>
<p>On success, should print PASS.</p>
</body>
</html>
|