LibWeb: Don't crash when cloning a CDATASection node

This commit is contained in:
Tim Ledbetter 2024-07-23 21:08:46 +01:00 committed by Sam Atkins
commit 72ed62a560
Notes: github-actions[bot] 2024-07-25 14:58:32 +00:00
3 changed files with 15 additions and 3 deletions

View file

@ -0,0 +1,9 @@
<script src="../include.js"></script>
<script>
test(() => {
const xmlDocument = new DOMParser().parseFromString(`<xml></xml>`, "application/xml");
const cdata = xmlDocument.createCDATASection("PASS");
const clone = cdata.cloneNode();
println(`Cloned CDATASection node data: ${clone.data}`);
});
</script>