mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-19 07:22:21 +00:00
LibWebView+UI: Migrate some UI process init to LibWebView
No need to do this setup in every UI's main().
This commit is contained in:
parent
6430b215af
commit
39da2d9a2f
Notes:
github-actions[bot]
2025-06-11 11:27:28 +00:00
Author: https://github.com/trflynn89
Commit: 39da2d9a2f
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5054
10 changed files with 80 additions and 91 deletions
|
@ -9,6 +9,7 @@
|
|||
#include <AK/Platform.h>
|
||||
#include <LibCore/Directory.h>
|
||||
#include <LibCore/Environment.h>
|
||||
#include <LibCore/Process.h>
|
||||
#include <LibCore/Resource.h>
|
||||
#include <LibCore/ResourceImplementationFile.h>
|
||||
#include <LibCore/System.h>
|
||||
|
@ -122,4 +123,18 @@ ErrorOr<Vector<ByteString>> get_paths_for_helper_process(StringView process_name
|
|||
return paths;
|
||||
}
|
||||
|
||||
ErrorOr<void> handle_attached_debugger()
|
||||
{
|
||||
#if defined(AK_OS_LINUX)
|
||||
// Let's ignore SIGINT if we're being debugged because GDB incorrectly forwards the signal to us even when it's set
|
||||
// to "nopass". See https://sourceware.org/bugzilla/show_bug.cgi?id=9425 for details.
|
||||
if (TRY(Core::Process::is_being_debugged())) {
|
||||
dbgln("Debugger is attached, ignoring SIGINT");
|
||||
TRY(Core::System::signal(SIGINT, SIG_IGN));
|
||||
}
|
||||
#endif
|
||||
|
||||
return {};
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue