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

uname: Use pledge()

This commit is contained in:
Andreas Kling 2020-02-18 13:28:08 +01:00
parent feb4c683eb
commit f67f70302b

View file

@ -26,9 +26,15 @@
#include <stdio.h>
#include <sys/utsname.h>
#include <unistd.h>
int main(int argc, char** argv)
{
if (pledge("stdio", nullptr) < 0) {
perror("pledge");
return 1;
}
utsname uts;
int rc = uname(&uts);
if (rc < 0) {