mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 16:17:45 +00:00
WindowServer: Use pledge()
This commit is contained in:
parent
0ad491a854
commit
d2e49719c4
1 changed files with 10 additions and 0 deletions
|
@ -10,6 +10,11 @@
|
||||||
|
|
||||||
int main(int, char**)
|
int main(int, char**)
|
||||||
{
|
{
|
||||||
|
if (pledge("stdio shared_buffer rpath wpath cpath unix proc fattr", nullptr) < 0) {
|
||||||
|
perror("pledge");
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
struct sigaction act;
|
struct sigaction act;
|
||||||
memset(&act, 0, sizeof(act));
|
memset(&act, 0, sizeof(act));
|
||||||
act.sa_flags = SA_NOCLDWAIT;
|
act.sa_flags = SA_NOCLDWAIT;
|
||||||
|
@ -30,6 +35,11 @@ int main(int, char**)
|
||||||
|
|
||||||
WSEventLoop loop;
|
WSEventLoop loop;
|
||||||
|
|
||||||
|
if (pledge("stdio shared_buffer rpath wpath cpath unix proc", nullptr) < 0) {
|
||||||
|
perror("pledge");
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
WSScreen screen(wm_config->read_num_entry("Screen", "Width", 1024),
|
WSScreen screen(wm_config->read_num_entry("Screen", "Width", 1024),
|
||||||
wm_config->read_num_entry("Screen", "Height", 768));
|
wm_config->read_num_entry("Screen", "Height", 768));
|
||||||
WSCompositor::the();
|
WSCompositor::the();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue