aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors
diff options
context:
space:
mode:
authorDario Lombardo <lomato@gmail.com>2020-06-17 16:40:45 +0200
committerPeter Wu <peter@lekensteyn.nl>2020-06-18 19:55:39 +0000
commit2f4bb252872614a78d768578739a329da8780dae (patch)
tree6ddcd3c4f2f40e2763896b299519e5f6db853d43 /epan/dissectors
parentfdf9610b84af9036d7a24ec4b46ffeb68cb66060 (diff)
rtps: fix compilation with and without ZLIB.
Set the options of rtps_add_zlib_compressed_typeobject used or unused according to the presence of zlib. Change-Id: I73d995fce9ec5a65b0d6ebce6c2510b6d25ad347 Reviewed-on: https://code.wireshark.org/review/37495 Petri-Dish: Dario Lombardo <lomato@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Diffstat (limited to 'epan/dissectors')
-rw-r--r--epan/dissectors/packet-rtps.c16
1 files changed, 11 insertions, 5 deletions
diff --git a/epan/dissectors/packet-rtps.c b/epan/dissectors/packet-rtps.c
index 088e4bc7eb..bee7ec5ca3 100644
--- a/epan/dissectors/packet-rtps.c
+++ b/epan/dissectors/packet-rtps.c
@@ -4084,11 +4084,11 @@ static void rtps_util_add_typeobject(proto_tree *tree, packet_info * pinfo,
}
-static void rtps_add_zlib_compressed_typeobject(proto_tree *tree _U_, packet_info * pinfo _U_,
- tvbuff_t * tvb _U_, gint offset _U_, const guint encoding _U_, guint compressed_size _U_,
- guint decompressed_size _U_, type_mapping * type_mapping_object) {
-
#ifdef HAVE_ZLIB
+static void rtps_add_zlib_compressed_typeobject(proto_tree *tree, packet_info * pinfo,
+ tvbuff_t * tvb, gint offset, const guint encoding, guint compressed_size,
+ guint decompressed_size, type_mapping * type_mapping_object) {
+
tvbuff_t *decompressed_data_child_tvb;
tvbuff_t *compressed_type_object_subset;
proto_tree *decompressed_type_object_subtree;
@@ -4105,8 +4105,14 @@ static void rtps_add_zlib_compressed_typeobject(proto_tree *tree _U_, packet_inf
proto_tree_add_subtree(tree, compressed_type_object_subset,
0, 0, ett_rtps_decompressed_type_object, NULL, "[Failed to decompress type object]");
}
-#endif
}
+#else
+static void rtps_add_zlib_compressed_typeobject(proto_tree *tree _U_, packet_info * pinfo _U_,
+ tvbuff_t * tvb _U_, gint offset _U_, const guint encoding _U_, guint compressed_size _U_,
+ guint decompressed_size _U_, type_mapping * type_mapping_object _U_)
+{
+}
+#endif
/* ------------------------------------------------------------------------- */
/* Insert in the protocol tree the next bytes interpreted as Sequence of