poll: suppress a warning
authorJim Meyering <meyering@redhat.com>
Fri, 16 Jan 2009 08:36:21 +0000 (09:36 +0100)
committerJim Meyering <meyering@redhat.com>
Fri, 16 Jan 2009 08:36:21 +0000 (09:36 +0100)
* lib/poll.c: Use #pragma GCC diagnostic ignored "-Wtype-limits"
to ignore "...unsigned expression < 0 is always false" warnings.

ChangeLog
lib/poll.c

index f07972be291e01bf01e4a17ec6dcecb6bdf49caf..9683602b086f351ce7bb30384411e91e766e215b 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2009-01-16  Jim Meyering  <meyering@redhat.com>
+
+       poll: suppress a warning
+       * lib/poll.c: Use #pragma GCC diagnostic ignored "-Wtype-limits"
+       to ignore "...unsigned expression < 0 is always false" warnings.
+
 2009-01-16  Daniel P. Berrange  <berrange@redhat.com>
 
        poll: remove declarations of unused variables
index bc7721cd0b58bfd0cecc45eac3287e2de420646b..ed76098036e922ce6016b38e8c64b590f4b5ffec 100644 (file)
    with this program; if not, write to the Free Software Foundation,
    Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.  */
 
+/* Tell gcc not to warn about the (nfd < 0) tests, below.  */
+#if (__GNUC__ == 4 && 3 <= __GNUC_MINOR__) || 4 < __GNUC__
+# pragma GCC diagnostic ignored "-Wtype-limits"
+#endif
+
 #include <config.h>
 #include <alloca.h>