From f34fd6a906b6dafe4a5fba13a622b12358510bef Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Sun, 19 Jun 2022 23:29:07 -0500 Subject: [PATCH 1/2] fchmodat: pacify gcc -Wunused-variable Problem reported by Bruno Haible in: https://lists.gnu.org/r/bug-gnulib/2022-06/msg00075.html * lib/fchmodat.c (fchmodat): Remove unused local. --- ChangeLog | 7 +++++++ lib/fchmodat.c | 1 - 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index c9975f436b..a815ca62cd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2022-06-19 Paul Eggert + + fchmodat: pacify gcc -Wunused-variable + Problem reported by Bruno Haible in: + https://lists.gnu.org/r/bug-gnulib/2022-06/msg00075.html + * lib/fchmodat.c (fchmodat): Remove unused local. + 2022-06-19 Bruno Haible getlogin, getlogin_r tests: Really avoid test failure. diff --git a/lib/fchmodat.c b/lib/fchmodat.c index 8ed4cb7398..164e2c4a95 100644 --- a/lib/fchmodat.c +++ b/lib/fchmodat.c @@ -96,7 +96,6 @@ fchmodat (int dir, char const *file, mode_t mode, int flags) return fd; int err; - char buf[1]; if (0 <= readlinkat (fd, "", readlink_buf, sizeof readlink_buf)) err = EOPNOTSUPP; else if (errno == EINVAL) -- 2.36.1