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

Playground: Use pledge()

This commit is contained in:
Linus Groh 2021-01-02 01:43:21 +01:00 committed by Andreas Kling
parent fb7cc4ec46
commit 7d72168b14

View file

@ -166,7 +166,18 @@ private:
int main(int argc, char** argv)
{
if (pledge("stdio thread shared_buffer accept cpath rpath wpath unix fattr", nullptr) < 0) {
perror("pledge");
return 1;
}
auto app = GUI::Application::construct(argc, argv);
if (pledge("stdio thread shared_buffer accept rpath cpath wpath", nullptr) < 0) {
perror("pledge");
return 1;
}
auto app_icon = GUI::Icon::default_icon("app-playground");
auto window = GUI::Window::construct();
window->set_title("GML Playground");