Revert "ws80211: Disable shorten-64-to-32."
authorJoão Valverde <joao.valverde@tecnico.ulisboa.pt>
Sun, 22 May 2016 02:37:14 +0000 (03:37 +0100)
committerJoão Valverde <j@v6e.pt>
Sun, 22 May 2016 04:55:34 +0000 (04:55 +0000)
This reverts commit b8f90de70efa2d271274fbb48df12737f6eddd12.

Change-Id: Ic7eaf288d1937a986c2ec85ba43a94ac20b6e12e
Reviewed-on: https://code.wireshark.org/review/15520
Reviewed-by: João Valverde <j@v6e.pt>
caputils/ws80211_utils.c
ws_diag_control.h

index a8f23a719818117c1ff1faa99882bd85c8f82723..66e935fa87a1f5e310ad38c063d3a0c77ab66d52 100644 (file)
@@ -727,8 +727,6 @@ out_err:
        return -1;
 }
 
-/* Needed for NLA_PUT_STRING, which passes strlen as an int */
-DIAG_OFF(shorten-64-to-32)
 static int ws80211_create_on_demand_interface(const char *name)
 {
        int devidx, phyidx, err;
@@ -767,7 +765,6 @@ nla_put_failure:
        fprintf(stderr, "building message failed\n");
        return 2;
 }
-DIAG_ON(shorten-64-to-32)
 
 int ws80211_set_freq(const char *name, int freq, int chan_type, int _U_ center_freq, int _U_ center_freq2)
 {
index cc0e9eec257721af6f240746441bcc0672948658..be6df0353cb3fd5cf3e329e91e0b60584044b8e7 100644 (file)
@@ -53,17 +53,7 @@ extern "C" {
       * gcc supports "-Wpedantic".
       */
 #    define DIAG_PRAGMA(x) DIAG_DO_PRAGMA(GCC diagnostic x)
-     /*
-      * DIAG_OFF generates
-      *
-      * #pragma GCC diagnostic push
-      * #pragma GCC diagnostic ignored "-Wpragmas"
-      * #pragma GCC diagnostic ignored "-Wx-aka-the-warning-in-question"
-      *
-      * Ignoring "-Wpragmas" lets us turn off diagnostics for clang warnings
-      * that might not be recognized by gcc.
-      */
-#    define DIAG_OFF(x) DIAG_PRAGMA(push) DIAG_PRAGMA(ignored DIAG_JOINSTR(-W,pragmas)) DIAG_PRAGMA(ignored DIAG_JOINSTR(-W,x))
+#    define DIAG_OFF(x) DIAG_PRAGMA(push) DIAG_PRAGMA(ignored DIAG_JOINSTR(-W,x))
 #    define DIAG_ON(x) DIAG_PRAGMA(pop)
 #  endif
 #elif defined(__clang__)