From ad5ee27ea99b87fb85e3af85f6255b17ca991747 Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Mon, 13 Jan 2020 12:30:12 +0100 Subject: [PATCH] mv: Use pledge() --- Userland/mv.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Userland/mv.cpp b/Userland/mv.cpp index 859b82dc7b..7e487e888d 100644 --- a/Userland/mv.cpp +++ b/Userland/mv.cpp @@ -1,11 +1,16 @@ -#include #include +#include #include #include #include int main(int argc, char** argv) { + if (pledge("stdio rpath wpath cpath fattr", nullptr) < 0) { + perror("pledge"); + return 1; + } + if (argc != 3) { printf("usage: mv \n"); return 1;