diff options
author | Guy Harris <guy@alum.mit.edu> | 2015-02-16 11:32:39 -0800 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2015-02-16 19:33:57 +0000 |
commit | cfb1bc3bb44d6b5a12eac28905b02e6a3a60d17b (patch) | |
tree | 6e75b150888d6a67bd76af6dc667527b809ca770 /epan/dissectors/packet-infiniband.c | |
parent | 4765bbc2a906a6ce4f141aa5beb46c553b4667bd (diff) | |
download | wireshark-cfb1bc3bb44d6b5a12eac28905b02e6a3a60d17b.tar.gz |
Put the 64-bit hash routines into a common file.
Some or all are used by the Infiniband, MBIM, and RSVD dissectors; put
them into a common source file, with a header for them, and just include
the header in the dissectors.
Change-Id: I724f0c2232ba751ccbd491222af6f03bafd6d63c
Reviewed-on: https://code.wireshark.org/review/7182
Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'epan/dissectors/packet-infiniband.c')
-rw-r--r-- | epan/dissectors/packet-infiniband.c | 19 |
1 files changed, 1 insertions, 18 deletions
diff --git a/epan/dissectors/packet-infiniband.c b/epan/dissectors/packet-infiniband.c index 350c895233..33fe8ea7be 100644 --- a/epan/dissectors/packet-infiniband.c +++ b/epan/dissectors/packet-infiniband.c @@ -25,13 +25,13 @@ #include "config.h" - #include <epan/packet.h> #include <epan/exceptions.h> #include <epan/conversation.h> #include <epan/prefs.h> #include <epan/etypes.h> #include <epan/show_exception.h> +#include <epan/g_int64_hash_routines.h> #include <wiretap/erf.h> #include "packet-infiniband.h" @@ -1489,23 +1489,6 @@ static heur_dissector_list_t heur_dissectors_cm_private; /* ----- This sections contains various utility functions indirectly related to Infiniband dissection ---- */ -/* g_int64_hash, g_int64_equal are defined starting glib 2.22 - otherwise, we'll have to - provide them ourselves! */ -#if !GLIB_CHECK_VERSION(2,22,0) -guint -g_int64_hash (gconstpointer v) -{ - return (guint) *(const gint64*) v; -} - -gboolean -g_int64_equal (gconstpointer v1, - gconstpointer v2) -{ - return *((const gint64*) v1) == *((const gint64*) v2); -} -#endif - static void table_destroy_notify(gpointer data) { g_free(data); } |