diff options
Diffstat (limited to 'epan/dissectors/packet-omron-fins.c')
-rw-r--r-- | epan/dissectors/packet-omron-fins.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/epan/dissectors/packet-omron-fins.c b/epan/dissectors/packet-omron-fins.c index 9ac66ece2b..2dcd75de43 100644 --- a/epan/dissectors/packet-omron-fins.c +++ b/epan/dissectors/packet-omron-fins.c @@ -1189,7 +1189,7 @@ dissect_omron_fins(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *da if (cmd_str_idx == -1) { /* Unknown command-code */ expert_add_info(pinfo, ti, &ei_omron_command_code); - return tvb_length(tvb); + return tvb_captured_length(tvb); } /* Handle special cases wherein the data length for a command and/or a response can be 0 */ @@ -1209,7 +1209,7 @@ dissect_omron_fins(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *da if (reported_length_remaining != 0) { expert_add_info_format(pinfo, omron_tree, &ei_omron_bad_length, "Unexpected Length (Should be 0)"); } - return tvb_length(tvb); + return tvb_captured_length(tvb); } break; @@ -1225,14 +1225,14 @@ dissect_omron_fins(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *da { expert_add_info_format(pinfo, ti, &ei_omron_command_code, "Unknown Response Command-Code"); } - return tvb_length(tvb); + return tvb_captured_length(tvb); break; case 0x0801: /* command data length = 0 or > 0 is OK; */ if (is_command) { if (reported_length_remaining == 0) - return tvb_length(tvb); + return tvb_captured_length(tvb); } break; @@ -1240,13 +1240,13 @@ dissect_omron_fins(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *da /* command data length = 0 or > 0 is OK; */ if (is_command) { if (reported_length_remaining == 0) - return tvb_length(tvb); + return tvb_captured_length(tvb); } /* There's no response */ if (is_response) { expert_add_info_format(pinfo, ti, &ei_omron_command_code, "Unknown Response Command-Code"); - return tvb_length(tvb); + return tvb_captured_length(tvb); } break; @@ -1475,7 +1475,7 @@ dissect_omron_fins(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *da if(memory_code_len == 0) { expert_add_info_format(pinfo, ti, &ei_oomron_command_memory_area_code, "Unknown Memory-Area-Code (%u)", memory_area_code); - return tvb_length(tvb); /* Bail out .... */ + return tvb_captured_length(tvb); /* Bail out .... */ } proto_tree_add_item(command_tree, hf_omron_data, tvb, offset, memory_code_len, ENC_NA); offset = offset + memory_code_len; @@ -3216,7 +3216,7 @@ dissect_omron_fins(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *da } /* if(tree) */ - return tvb_length(tvb); + return tvb_captured_length(tvb); } void |