optimizations #161

Open
emma wants to merge 44 commits from optimizations into main
Showing only changes of commit 9f520df82b - Show all commits

View File

@ -20,7 +20,7 @@
#include <sysexits.h> /* EX_OK, EX_OSERR, EX_USAGE */
#ifdef __OpenBSD__
# include <unistd.h> /* pledge(2) */
# include <unistd.h> /* pledge(2), unveil(2) */
#endif
char *program_name = "strcmp";
@ -29,7 +29,7 @@ int main(int argc, char *argv[]) {
unsigned int i;
#ifdef __OpenBSD__
if (pledge("stdio", NULL) == -1) {
if (pledge("stdio unveil", NULL) == -1 || unveil(NULL, NULL) == -1) {
perror(argv[0] == NULL ? program_name : argv[0]);
return EX_OSERR;