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

Calculator: Use unveil()

A barebones GUI app like this only needs read access to /res (for fonts
and themes, in case settings change) once it's up and running.
This commit is contained in:
Andreas Kling 2020-01-21 12:03:08 +01:00
parent 1b3cac2f42
commit 39931733a5

View file

@ -47,6 +47,13 @@ int main(int argc, char** argv)
return 1;
}
if (unveil("/res", "r") < 0) {
perror("unveil");
return 1;
}
unveil(nullptr, nullptr);
auto window = GWindow::construct();
window->set_title("Calculator");
window->set_resizable(false);