summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAli Mohammad Pur <ali.mpfard@gmail.com>2022-02-07 23:43:39 +0330
committerAndreas Kling <kling@serenityos.org>2022-02-07 21:52:23 +0100
commit3bf828e0f97e06a486958848ad74d5f1bbc9575c (patch)
treec86659d88325296fcac7b944eb8deb3ce2dbdd12
parent673e6f3a329f3bdc60dda453d874290f8e408420 (diff)
downloadserenity-3bf828e0f97e06a486958848ad74d5f1bbc9575c.zip
RequestServer: Reenable socket notifications unconditionally
There's a possible window where the notifications are disabled, and any request coming at that time will never get any data if it relies on socket notifications.
-rw-r--r--Userland/Services/RequestServer/ConnectionCache.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/Userland/Services/RequestServer/ConnectionCache.cpp b/Userland/Services/RequestServer/ConnectionCache.cpp
index 6582ad2059..fc5aea4c43 100644
--- a/Userland/Services/RequestServer/ConnectionCache.cpp
+++ b/Userland/Services/RequestServer/ConnectionCache.cpp
@@ -64,6 +64,7 @@ void request_did_finish(URL const& url, Core::Stream::Socket const* socket)
connection->timer.start();
connection->current_url = url;
connection->job_data = connection->request_queue.take_first();
+ connection->socket->set_notifications_enabled(true);
connection->job_data.start(*connection->socket);
});
}