logo

utils-std

Collection of commonly available Unix tools git clone https://anongit.hacktivis.me/git/utils-std.git/
commit: 7eb90fd3a7a48876114c76f2345dd33b2442cfe9
parent b3ab3d34022c4edf3b3832177b1302fd9c70d192
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date:   Thu, 24 Jul 2025 20:06:35 +0200

cmd/getconf: assert(buf) before fwrite(buf, …)

Diffstat:

Mcmd/getconf.c2++
1 file changed, 2 insertions(+), 0 deletions(-)

diff --git a/cmd/getconf.c b/cmd/getconf.c @@ -246,6 +246,8 @@ main(int argc, char *argv[]) continue; } + assert(buf); + printf("%s: ", confstr_vars[i].name); fwrite(buf, (ret - 1), 1, stdout); printf("\n");