mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 07:30:19 +00:00
LibWeb: Assert that cloned node is not null before returning
This makes potential issues easier to track down.
This commit is contained in:
parent
72ed62a560
commit
f8b1e96e2b
Notes:
github-actions[bot]
2024-07-25 14:58:26 +00:00
Author: https://github.com/tcl3 Commit: https://github.com/LadybirdBrowser/ladybird/commit/f8b1e96e2be Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/798 Reviewed-by: https://github.com/AtkinsSJ ✅ Reviewed-by: https://github.com/trflynn89
1 changed files with 1 additions and 0 deletions
|
@ -1040,6 +1040,7 @@ WebIDL::ExceptionOr<JS::NonnullGCPtr<Node>> Node::clone_node(Document* document,
|
|||
}
|
||||
|
||||
// 7. Return copy.
|
||||
VERIFY(copy);
|
||||
return JS::NonnullGCPtr { *copy };
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue