diff options
author | Brian Gianforcaro <b.gianfo@gmail.com> | 2020-01-12 16:12:18 -0800 |
---|---|---|
committer | Andreas Kling <awesomekling@gmail.com> | 2020-01-13 11:04:35 +0100 |
commit | e45a4b0931045ef5b0380918e3459e600243e2ed (patch) | |
tree | 7b5cc7aad89bbf6c223752fd71eb2e376d714f46 /Userland/md.cpp | |
parent | a77da7f2458622ebd64cc088485b98d99ca92d79 (diff) | |
download | serenity-e45a4b0931045ef5b0380918e3459e600243e2ed.zip |
md: Use pledge()
Diffstat (limited to 'Userland/md.cpp')
-rw-r--r-- | Userland/md.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/Userland/md.cpp b/Userland/md.cpp index 31ef0fe421..7c471e05db 100644 --- a/Userland/md.cpp +++ b/Userland/md.cpp @@ -5,6 +5,11 @@ int main(int argc, char* argv[]) { + if (pledge("stdio rpath", nullptr) < 0) { + perror("pledge"); + return 1; + } + const char* file_name = nullptr; bool html = false; @@ -27,6 +32,11 @@ int main(int argc, char* argv[]) return 1; } + if (pledge("stdio", nullptr) < 0) { + perror("pledge"); + return 1; + } + auto buffer = file->read_all(); dbg() << "Read size " << buffer.size(); |