From 22149c5523a77e642ec13d12064b2ccef29e51fb Mon Sep 17 00:00:00 2001 From: Evan Huus Date: Sat, 22 Feb 2014 08:39:57 -0500 Subject: TVB API deprecations and cleanup - rename tvb_length and similar to tvb_captured_length and similar; leave #defines in place for backwards-compat, but mark them clearly as deprecated in code comments and in checkAPI - remove tvb_get_string as C code and just leave a #define in place for backwards-compat; mark it clearly as deprecated in code comment and checkAPI - update READMEs and sample dissector for all of the above - while in the neighbourhood, make checkAPI skip (and warn) for missing files instead of bailing on the whole check, so subsequent files still get checked Change-Id: I32fc437896ca86ca73e9b49d5f50400adf8ec5ad Reviewed-on: https://code.wireshark.org/review/311 Reviewed-by: Evan Huus --- doc/packet-PROTOABBREV.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'doc/packet-PROTOABBREV.c') diff --git a/doc/packet-PROTOABBREV.c b/doc/packet-PROTOABBREV.c index 1e4c9975d6..c1aaba8d36 100644 --- a/doc/packet-PROTOABBREV.c +++ b/doc/packet-PROTOABBREV.c @@ -97,7 +97,7 @@ dissect_PROTOABBREV(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, */ /* Check that there's enough data */ - if (tvb_length(tvb) < PROTOABBREV_MIN_LENGTH) + if (tvb_reported_length(tvb) < PROTOABBREV_MIN_LENGTH) return 0; /* Fetch some values from the packet header using tvb_get_*(). If these @@ -181,8 +181,8 @@ dissect_PROTOABBREV(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, * README.dissector for more information. */ /* Return the amount of data this dissector was able to dissect (which may - * or may not be the entire packet as we return here). */ - return tvb_length(tvb); + * or may not be the total captured packet as we return here). */ + return tvb_captured_length(tvb); } /* Register the protocol with Wireshark. -- cgit v1.2.3