From: Kyle Ackerman Subject: Redundant pledge(2) call in dmesg To: "tech@openbsd.org" Date: Thu, 21 Nov 2024 03:49:10 +0000 There is a redundant call to pledge(2) in dmesg.c diff /usr/src commit - 61e9d0de7a4c2cb6906206c99b245d89b1ad9d87 path + /usr/src blob - 29fb0a8032dad8c4250366ad4146bf55fca3f9d0 file + sbin/dmesg/dmesg.c --- sbin/dmesg/dmesg.c +++ sbin/dmesg/dmesg.c @@ -128,9 +128,6 @@ main(int argc, char *argv[]) "dmesg")) == NULL) return (1); - if (pledge("stdio", NULL) == -1) - err(1, "pledge"); - if (kvm_nlist(kd, nl) == -1) errx(1, "kvm_nlist: %s", kvm_geterr(kd)); if (nl[X_MSGBUF].n_type == 0) Regardless if NOKVM is defined or not, the pledge call will remain.