mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 06:27:45 +00:00
which: Use pledge()
This commit is contained in:
parent
7266cee590
commit
0b44f9d600
1 changed files with 5 additions and 0 deletions
|
@ -31,6 +31,11 @@
|
||||||
|
|
||||||
int main(int argc, char** argv)
|
int main(int argc, char** argv)
|
||||||
{
|
{
|
||||||
|
if (pledge("stdio rpath", nullptr) < 0) {
|
||||||
|
perror("pledge");
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
if (argc < 2) {
|
if (argc < 2) {
|
||||||
printf("usage: which <executable>\n");
|
printf("usage: which <executable>\n");
|
||||||
return 0;
|
return 0;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue