From: Jim Meyering Date: Sat, 24 Sep 2011 19:02:15 +0000 (+0200) Subject: test-futimens: avoid a warning from gcc -Wshadow X-Git-Tag: v0.1~1749 X-Git-Url: http://erislabs.org.uk/gitweb/?a=commitdiff_plain;h=90520caf3cfe735b83237a11034b7aa0c3bb05b9;p=gnulib.git test-futimens: avoid a warning from gcc -Wshadow * tests/test-futimens.h (test_futimens): Rename inner local, s/fd/fd0/ to avoid a shadowing warning. --- diff --git a/ChangeLog b/ChangeLog index 9def2635e..f154617a4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2011-09-24 Jim Meyering + + test-futimens: avoid a warning from gcc -Wshadow + * tests/test-futimens.h (test_futimens): Rename inner local, s/fd/fd0/ + to avoid a shadowing warning. + 2011-09-24 Bruno Haible fdopen: Support for MSVC 9. diff --git a/tests/test-futimens.h b/tests/test-futimens.h index 2cd7c014b..9c9b1bb28 100644 --- a/tests/test-futimens.h +++ b/tests/test-futimens.h @@ -90,11 +90,11 @@ test_futimens (int (*func) (int, struct timespec const *), ASSERT (errno == EBADF); } { - int fd = dup (0); - ASSERT (0 <= fd); - ASSERT (close (fd) == 0); + int fd0 = dup (0); + ASSERT (0 <= fd0); + ASSERT (close (fd0) == 0); errno = 0; - ASSERT (func (fd, NULL) == -1); + ASSERT (func (fd0, NULL) == -1); ASSERT (errno == EBADF); } {