mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-31 05:09:12 +00:00
LibWeb: Don't hold on to the Download instance after it's finished
Fixes* 4668
This commit is contained in:
parent
a6b04cf8ef
commit
83fed3fd5d
Notes:
sideshowbarker
2024-07-19 00:18:30 +09:00
Author: https://github.com/alimpfard
Commit: 83fed3fd5d
Pull-request: https://github.com/SerenityOS/serenity/pull/4672
Issue: https://github.com/SerenityOS/serenity/issues/4668
Reviewed-by: https://github.com/awesomekling
Reviewed-by: https://github.com/tomuta
1 changed files with 1 additions and 0 deletions
|
@ -184,6 +184,7 @@ void ResourceLoader::load(const LoadRequest& request, Function<void(ReadonlyByte
|
|||
error_callback("HTTP load failed");
|
||||
return;
|
||||
}
|
||||
deferred_invoke([&](auto&) { const_cast<RefPtr<Protocol::Download>&>(download) = nullptr; });
|
||||
success_callback(payload, response_headers);
|
||||
};
|
||||
download->set_should_buffer_all_input(true);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue