diff options
author | Timothy Flynn <trflynn89@pm.me> | 2023-03-17 10:56:59 -0400 |
---|---|---|
committer | Linus Groh <mail@linusgroh.de> | 2023-03-17 16:39:08 +0000 |
commit | 6e1b5b541adff55de3cdccf4a5803cc14fd72034 (patch) | |
tree | 1092fa3159486cf6d5402a1ac5365fb718756aa2 /Userland/Services | |
parent | 13dfadba797799f66c2c369cc5fb489c35184c02 (diff) | |
download | serenity-6e1b5b541adff55de3cdccf4a5803cc14fd72034.zip |
LibWeb: Move initialization of the MainThreadVM to WebContent's main()
It is a fallible operation, so this lets us abort early if it fails.
Diffstat (limited to 'Userland/Services')
-rw-r--r-- | Userland/Services/WebContent/main.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Userland/Services/WebContent/main.cpp b/Userland/Services/WebContent/main.cpp index 6403fb95a2..caa0a2e48d 100644 --- a/Userland/Services/WebContent/main.cpp +++ b/Userland/Services/WebContent/main.cpp @@ -12,6 +12,7 @@ #include <LibCore/System.h> #include <LibIPC/SingleServer.h> #include <LibMain/Main.h> +#include <LibWeb/Bindings/MainThreadVM.h> #include <LibWeb/Loader/ResourceLoader.h> #include <LibWeb/Platform/EventLoopPlugin.h> #include <LibWeb/Platform/EventLoopPluginSerenity.h> @@ -45,6 +46,7 @@ ErrorOr<int> serenity_main(Main::Arguments) Web::WebSockets::WebSocketClientManager::initialize(TRY(WebView::WebSocketClientManagerAdapter::try_create())); Web::ResourceLoader::initialize(TRY(WebView::RequestServerAdapter::try_create())); + TRY(Web::Bindings::initialize_main_thread_vm()); auto client = TRY(IPC::take_over_accepted_client_from_system_server<WebContent::ConnectionFromClient>()); return event_loop.exec(); |