]> Savannah Git Hosting - gnulib.git/commitdiff
fchmodat: pacify gcc -Wunused-variable
authorPaul Eggert <eggert@cs.ucla.edu>
Mon, 20 Jun 2022 04:29:07 +0000 (23:29 -0500)
committerBruno Haible <bruno@clisp.org>
Wed, 31 Aug 2022 23:13:51 +0000 (01:13 +0200)
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
lib/fchmodat.c

index 4c5e1afc3c6cd0cbd02d576d87b4d38d3024b7c1..b675a3c524d8a97449465c5b4da10da902740cdf 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2022-06-19  Paul Eggert  <eggert@cs.ucla.edu>
+
+       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  <bruno@clisp.org>
 
        getlogin, getlogin_r tests: Really avoid test failure.
index e886ec4befa624713574bdef627a7fe38d3ff4b7..e67a75bf975dc283638226bc41f94a643fa103c8 100644 (file)
@@ -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)