mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-05-05 10:42:51 +00:00
Userland: Avoid some conversions from rvalue strings to StringView
These are all actually fine, there is no UAF here. But once e.g. `ByteString::view() &&` is deleted, these instances won't compile.
This commit is contained in:
parent
23b25333a5
commit
683c08744a
Notes:
sideshowbarker
2024-07-17 03:59:29 +09:00
Author: https://github.com/trflynn89
Commit: 683c08744a
Pull-request: https://github.com/SerenityOS/serenity/pull/23830
Reviewed-by: https://github.com/shannonbooth ✅
17 changed files with 48 additions and 26 deletions
|
@ -117,7 +117,9 @@ JS::ThrowCompletionOr<Optional<JS::PropertyDescriptor>> WindowProxy::internal_ge
|
|||
|
||||
// 6. If property is undefined and P is in W's document-tree child navigable target name property set, then:
|
||||
auto navigable_property_set = m_window->document_tree_child_navigable_target_name_property_set();
|
||||
if (auto navigable = navigable_property_set.get(property_key.to_string().view()); navigable.has_value()) {
|
||||
auto property_key_string = property_key.to_string();
|
||||
|
||||
if (auto navigable = navigable_property_set.get(property_key_string.view()); navigable.has_value()) {
|
||||
// 1. Let value be the active WindowProxy of the named object of W with the name P.
|
||||
auto value = navigable.value()->active_window_proxy();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue