LibWebView+UI: Raise the chrome process open file limit

The default limit (at least on Linux) causes us to run out of file
descriptors at around 15 tabs. Increase this limit to 8k. This is a
rather arbitrary number, but matches the limit set by Chrome.
This commit is contained in:
Timothy Flynn 2024-07-22 10:17:44 -04:00 committed by Andreas Kling
commit d58a8b5146
Notes: github-actions[bot] 2024-07-23 07:40:33 +00:00
4 changed files with 15 additions and 4 deletions

View file

@ -40,7 +40,7 @@ private:
class ChromeProcess {
AK_MAKE_NONCOPYABLE(ChromeProcess);
AK_MAKE_NONMOVABLE(ChromeProcess);
AK_MAKE_DEFAULT_MOVABLE(ChromeProcess);
public:
enum class ProcessDisposition : u8 {
@ -48,7 +48,7 @@ public:
ExitProcess,
};
ChromeProcess() = default;
static ErrorOr<ChromeProcess> create();
~ChromeProcess();
ErrorOr<ProcessDisposition> connect(Vector<ByteString> const& raw_urls, bool new_window);
@ -57,6 +57,8 @@ public:
Function<void(Vector<ByteString> const& raw_urls)> on_new_window;
private:
ChromeProcess() = default;
ErrorOr<void> connect_as_client(ByteString const& socket_path, Vector<ByteString> const& raw_urls, bool new_window);
ErrorOr<void> connect_as_server(ByteString const& socket_path);