|
|
@ -2,6 +2,7 @@
|
|
|
|
#include <sys/types.h>
|
|
|
|
#include <sys/types.h>
|
|
|
|
|
|
|
|
|
|
|
|
#include <ctype.h>
|
|
|
|
#include <ctype.h>
|
|
|
|
|
|
|
|
#include <err.h>
|
|
|
|
#include <errno.h>
|
|
|
|
#include <errno.h>
|
|
|
|
#include <fcntl.h>
|
|
|
|
#include <fcntl.h>
|
|
|
|
#include <fnmatch.h>
|
|
|
|
#include <fnmatch.h>
|
|
|
@ -750,6 +751,9 @@ main(int argc, char *argv[])
|
|
|
|
if (!rflag && !Oflag && !Rflag)
|
|
|
|
if (!rflag && !Oflag && !Rflag)
|
|
|
|
safe_output = 1;
|
|
|
|
safe_output = 1;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (pledge("stdio rpath tty cpath proc", NULL) == -1)
|
|
|
|
|
|
|
|
err(1, "pledge");
|
|
|
|
|
|
|
|
|
|
|
|
if (safe_output && isatty(1)) {
|
|
|
|
if (safe_output && isatty(1)) {
|
|
|
|
char *pg;
|
|
|
|
char *pg;
|
|
|
|
pg = getenv("MBLAZE_PAGER");
|
|
|
|
pg = getenv("MBLAZE_PAGER");
|
|
|
@ -766,6 +770,9 @@ main(int argc, char *argv[])
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (pledge("stdio rpath cpath tty", NULL) == -1)
|
|
|
|
|
|
|
|
err(1, "pledge");
|
|
|
|
|
|
|
|
|
|
|
|
if (xflag) { // extract
|
|
|
|
if (xflag) { // extract
|
|
|
|
extract(xflag, argc-optind, argv+optind, 0);
|
|
|
|
extract(xflag, argc-optind, argv+optind, 0);
|
|
|
|
} else if (Oflag) { // extract to stdout
|
|
|
|
} else if (Oflag) { // extract to stdout
|
|
|
|