diff --git a/Services/WebContent/ConnectionFromClient.cpp b/Services/WebContent/ConnectionFromClient.cpp index e7db5e753f6..db5a6f0e530 100644 --- a/Services/WebContent/ConnectionFromClient.cpp +++ b/Services/WebContent/ConnectionFromClient.cpp @@ -56,9 +56,8 @@ namespace WebContent { -ConnectionFromClient::ConnectionFromClient(GC::Heap& heap, IPC::Transport transport) +ConnectionFromClient::ConnectionFromClient(IPC::Transport transport) : IPC::ConnectionFromClient(*this, move(transport), 1) - , m_heap(heap) , m_page_host(PageHost::create(*this)) { } diff --git a/Services/WebContent/ConnectionFromClient.h b/Services/WebContent/ConnectionFromClient.h index d288a3040b0..2d4b1f786b3 100644 --- a/Services/WebContent/ConnectionFromClient.h +++ b/Services/WebContent/ConnectionFromClient.h @@ -51,7 +51,7 @@ public: Queue& input_event_queue() { return m_input_event_queue; } private: - explicit ConnectionFromClient(GC::Heap&, IPC::Transport); + explicit ConnectionFromClient(IPC::Transport); Optional page(u64 index, SourceLocation = SourceLocation::current()); Optional page(u64 index, SourceLocation = SourceLocation::current()) const; @@ -157,7 +157,6 @@ private: virtual void system_time_zone_changed() override; - GC::Heap& m_heap; NonnullOwnPtr m_page_host; HashMap m_requested_files {}; diff --git a/Services/WebContent/main.cpp b/Services/WebContent/main.cpp index 857a28914e1..6882fb8a881 100644 --- a/Services/WebContent/main.cpp +++ b/Services/WebContent/main.cpp @@ -213,7 +213,7 @@ ErrorOr serenity_main(Main::Arguments arguments) static_assert(IsSame, "Need to handle other IPC transports here"); auto webcontent_socket = TRY(Core::take_over_socket_from_system_server("WebContent"sv)); - auto webcontent_client = TRY(WebContent::ConnectionFromClient::try_create(Web::Bindings::main_thread_vm().heap(), IPC::Transport(move(webcontent_socket)))); + auto webcontent_client = TRY(WebContent::ConnectionFromClient::try_create(IPC::Transport(move(webcontent_socket)))); webcontent_client->on_image_decoder_connection = [&](auto& socket_file) { auto maybe_error = reinitialize_image_decoder(socket_file);