1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 15:27:35 +00:00

Demos/CatDog: Introduce inspector & artist states based on open programs

These two new main states are determined by looking at the programs the
user has open. The artist state, using the new artist catdog, is
triggered by PixelPaint and FontEditor, and the inspector state is
triggered by Inspector, Profiler and SystemMonitor. This requires CatDog
to unveil /proc/all, and, for some reason, /etc/passwd.
This commit is contained in:
kleines Filmröllchen 2022-02-26 19:44:30 +01:00 committed by Andreas Kling
parent 93bb943394
commit 145f983ee1
3 changed files with 43 additions and 3 deletions

View file

@ -26,6 +26,9 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
TRY(Core::System::pledge("stdio recvfd sendfd rpath"));
TRY(Core::System::unveil("/res", "r"));
TRY(Core::System::unveil("/proc/all", "r"));
// FIXME: For some reason, this is needed in the /proc/all shenanigans.
TRY(Core::System::unveil("/etc/passwd", "r"));
TRY(Core::System::unveil(nullptr, nullptr));
auto window = TRY(GUI::Window::try_create());