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

cp: Use pledge()

This commit is contained in:
Andreas Kling 2020-01-13 12:30:07 +01:00
parent 56428e764e
commit 8ccc2b25c2

View file

@ -15,6 +15,11 @@ bool copy_directory(String, String);
int main(int argc, char** argv)
{
if (pledge("stdio rpath wpath cpath fattr", nullptr) < 0) {
perror("pledge");
return 1;
}
CArgsParser args_parser("cp");
args_parser.add_arg("r", "copy directories recursively");
args_parser.add_required_single_value("source");