date: Use pledge()

This commit is contained in:
Andreas Kling 2020-02-18 13:20:52 +01:00
parent 4b0e0bd9b8
commit 03aea11589
Notes: sideshowbarker 2024-07-19 09:14:05 +09:00

View File

@ -32,6 +32,11 @@
int main(int argc, char** argv)
{
if (pledge("stdio", nullptr) < 0) {
perror("pledge");
return 1;
}
time_t now = time(nullptr);
if (argc == 2 && !strcmp(argv[1], "-u")) {