diff options
author | Anders Broman <anders.broman@ericsson.com> | 2011-09-26 05:52:58 +0000 |
---|---|---|
committer | Anders Broman <anders.broman@ericsson.com> | 2011-09-26 05:52:58 +0000 |
commit | fc63c358435bc4bf771a0c15943a1aee890a2787 (patch) | |
tree | 8a9fc1879cbb0c4b9c4823078293dc5e8959b883 /epan/dissectors | |
parent | 69bfd68ac490f8d831614f4f1643265ef27a9bb4 (diff) |
Get rid of check_col() and use ENC_BIG_ENDIAN.
svn path=/trunk/; revision=39144
Diffstat (limited to 'epan/dissectors')
-rw-r--r-- | epan/dissectors/packet-acap.c | 20 | ||||
-rw-r--r-- | epan/dissectors/packet-adwin-config.c | 7 | ||||
-rw-r--r-- | epan/dissectors/packet-ajp13.c | 22 | ||||
-rw-r--r-- | epan/dissectors/packet-alcap.c | 330 | ||||
-rw-r--r-- | epan/dissectors/packet-ans.c | 24 | ||||
-rw-r--r-- | epan/dissectors/packet-aodv.c | 211 | ||||
-rw-r--r-- | epan/dissectors/packet-aoe.c | 49 | ||||
-rw-r--r-- | epan/dissectors/packet-app-pkix-cert.c | 5 | ||||
-rw-r--r-- | epan/dissectors/packet-arcnet.c | 13 | ||||
-rw-r--r-- | epan/dissectors/packet-armagetronad.c | 37 | ||||
-rw-r--r-- | epan/dissectors/packet-aruba-adp.c | 18 | ||||
-rw-r--r-- | epan/dissectors/packet-asap.c | 4 | ||||
-rw-r--r-- | epan/dissectors/packet-asf.c | 37 | ||||
-rw-r--r-- | epan/dissectors/packet-auto_rp.c | 11 |
14 files changed, 376 insertions, 412 deletions
diff --git a/epan/dissectors/packet-acap.c b/epan/dissectors/packet-acap.c index 634f32f3ea..44d6ec2038 100644 --- a/epan/dissectors/packet-acap.c +++ b/epan/dissectors/packet-acap.c @@ -65,7 +65,7 @@ dissect_acap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) * not longer than what's in the buffer, so the "tvb_get_ptr()" * call won't throw an exception. */ - linelen = tvb_find_line_end(tvb, offset, -1, &next_offset, FALSE); + linelen = tvb_find_line_end(tvb, offset, -1, &next_offset, ENC_BIG_ENDIAN); line = tvb_get_ptr(tvb, offset, linelen); if (pinfo->match_uint == pinfo->destport) @@ -73,19 +73,17 @@ dissect_acap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) else is_request = FALSE; - if (check_col(pinfo->cinfo, COL_INFO)) { - /* - * Put the first line from the buffer into the summary - * (but leave out the line terminator). - */ - col_add_fstr(pinfo->cinfo, COL_INFO, "%s: %s", - is_request ? "Request" : "Response", - format_text(line, linelen)); - } + /* + * Put the first line from the buffer into the summary + * (but leave out the line terminator). + */ + col_add_fstr(pinfo->cinfo, COL_INFO, "%s: %s", + is_request ? "Request" : "Response", + format_text(line, linelen)); if (tree) { ti = proto_tree_add_item(tree, proto_acap, tvb, offset, -1, - FALSE); + ENC_BIG_ENDIAN); acap_tree = proto_item_add_subtree(ti, ett_acap); if (is_request) { diff --git a/epan/dissectors/packet-adwin-config.c b/epan/dissectors/packet-adwin-config.c index 03d54609eb..ba43811817 100644 --- a/epan/dissectors/packet-adwin-config.c +++ b/epan/dissectors/packet-adwin-config.c @@ -503,10 +503,9 @@ dissect_adwin_config(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) DISSECTOR_ASSERT_NOT_REACHED(); } - if (check_col(pinfo->cinfo, COL_INFO)) - col_add_str(pinfo->cinfo, COL_INFO, - val_to_str(length, length_mapping, - "Unknown ADwin Configuration packet, length: %d")); + col_add_str(pinfo->cinfo, COL_INFO, + val_to_str(length, length_mapping, + "Unknown ADwin Configuration packet, length: %d")); } return (tvb_reported_length(tvb)); diff --git a/epan/dissectors/packet-ajp13.c b/epan/dissectors/packet-ajp13.c index 8b3981d8e3..9b0ac3cc67 100644 --- a/epan/dissectors/packet-ajp13.c +++ b/epan/dissectors/packet-ajp13.c @@ -522,8 +522,7 @@ display_req_forward(tvbuff_t *tvb, packet_info *pinfo, pos=pos+uri_len; /* skip over chars + trailing null */ - if(check_col(pinfo->cinfo, COL_INFO)) - col_append_fstr(pinfo->cinfo, COL_INFO, " %s %s", uri, ver); + col_append_fstr(pinfo->cinfo, COL_INFO, " %s %s", uri, ver); /* REMOTE ADDRESS @@ -680,16 +679,15 @@ dissect_ajp13_tcp_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) /* len = tvb_get_ntohs(tvb, 2); */ col_set_str(pinfo->cinfo, COL_PROTOCOL, "AJP13"); - if (check_col(pinfo->cinfo, COL_INFO)) { - if (mag == 0x1234 && !fd->is_request_body) - col_append_fstr(pinfo->cinfo, COL_INFO, "%d:REQ:", conv->index); - else if (mag == 0x1234 && fd->is_request_body) - col_append_fstr(pinfo->cinfo, COL_INFO, "%d:REQ:Body", conv->index); - else if (mag == 0x4142) - col_append_fstr(pinfo->cinfo, COL_INFO, "%d:RSP:", conv->index); - else - col_set_str(pinfo->cinfo, COL_INFO, "AJP13 Error?"); - } + + if (mag == 0x1234 && !fd->is_request_body) + col_append_fstr(pinfo->cinfo, COL_INFO, "%d:REQ:", conv->index); + else if (mag == 0x1234 && fd->is_request_body) + col_append_fstr(pinfo->cinfo, COL_INFO, "%d:REQ:Body", conv->index); + else if (mag == 0x4142) + col_append_fstr(pinfo->cinfo, COL_INFO, "%d:RSP:", conv->index); + else + col_set_str(pinfo->cinfo, COL_INFO, "AJP13 Error?"); if (tree) { proto_item *ti; diff --git a/epan/dissectors/packet-alcap.c b/epan/dissectors/packet-alcap.c index cd8cfedc07..474e6992f7 100644 --- a/epan/dissectors/packet-alcap.c +++ b/epan/dissectors/packet-alcap.c @@ -410,7 +410,7 @@ static emem_tree_t* legs_by_osaid = NULL; static emem_tree_t* legs_by_bearer = NULL; static const gchar* dissect_fields_unknown(packet_info* pinfo _U_, tvbuff_t *tvb, proto_tree *tree, int offset, int len, alcap_message_info_t* msg_info _U_) { - proto_item* pi = proto_tree_add_item(tree,hf_alcap_unknown,tvb,offset,len,FALSE); + proto_item* pi = proto_tree_add_item(tree,hf_alcap_unknown,tvb,offset,len,ENC_BIG_ENDIAN); proto_item_set_expert_flags(pi, PI_UNDECODED, PI_WARN); return NULL; } @@ -437,17 +437,17 @@ static const gchar* dissect_fields_cau(packet_info* pinfo, tvbuff_t *tvb, proto_ coding = tvb_get_guint8(tvb, offset) & 0x3; - proto_tree_add_item(tree, hf_alcap_cau_coding, tvb, offset, 1, FALSE); + proto_tree_add_item(tree, hf_alcap_cau_coding, tvb, offset, 1, ENC_BIG_ENDIAN); if (coding == 0) { - pi = proto_tree_add_item(tree, hf_alcap_cau_value_itu, tvb, offset+1, 1, FALSE); + pi = proto_tree_add_item(tree, hf_alcap_cau_value_itu, tvb, offset+1, 1, ENC_BIG_ENDIAN); if ( msg_info->release_cause && msg_info->release_cause != 31 ) expert_add_info_format(pinfo, pi, PI_RESPONSE_CODE, PI_WARN, "Abnormal Release"); ret_str = val_to_str(msg_info->release_cause, cause_values_itu, "Unknown(%u)"); } else { - proto_tree_add_item(tree, hf_alcap_cau_value_non_itu, tvb, offset+1 , 1, FALSE); + proto_tree_add_item(tree, hf_alcap_cau_value_non_itu, tvb, offset+1 , 1, ENC_BIG_ENDIAN); ret_str = ep_strdup_printf("%u", msg_info->release_cause); } @@ -458,21 +458,21 @@ static const gchar* dissect_fields_cau(packet_info* pinfo, tvbuff_t *tvb, proto_ if (len > 2) { int diag_len = tvb_get_guint8(tvb,offset); - pi = proto_tree_add_item(tree,hf_alcap_cau_diag, tvb, offset,len-2,FALSE); + pi = proto_tree_add_item(tree,hf_alcap_cau_diag, tvb, offset,len-2,ENC_BIG_ENDIAN); tree = proto_item_add_subtree(pi,ett_cau_diag); - proto_tree_add_item(tree, hf_alcap_cau_diag_len, tvb, offset, 1, FALSE); + proto_tree_add_item(tree, hf_alcap_cau_diag_len, tvb, offset, 1, ENC_BIG_ENDIAN); if (diag_len) { switch (msg_info->release_cause) { case 97: case 99: case 110: - proto_tree_add_item(tree, hf_alcap_cau_diag_msg, tvb, ++offset, 1, FALSE); + proto_tree_add_item(tree, hf_alcap_cau_diag_msg, tvb, ++offset, 1, ENC_BIG_ENDIAN); while(diag_len >= 2) { - proto_tree_add_item(tree, hf_alcap_cau_diag_param_id, tvb, ++offset, 1, FALSE); - proto_tree_add_item(tree, hf_alcap_cau_diag_field_num, tvb, ++offset, 1, FALSE); + proto_tree_add_item(tree, hf_alcap_cau_diag_param_id, tvb, ++offset, 1, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_cau_diag_field_num, tvb, ++offset, 1, ENC_BIG_ENDIAN); diag_len -= 2; } break; @@ -502,7 +502,7 @@ static const gchar* dissect_fields_ceid(packet_info* pinfo _U_, tvbuff_t *tvb, p return NULL; } - pi = proto_tree_add_item(tree,hf_alcap_ceid_pathid,tvb,offset,4,FALSE); + pi = proto_tree_add_item(tree,hf_alcap_ceid_pathid,tvb,offset,4,ENC_BIG_ENDIAN); msg_info->pathid = tvb_get_ntohl(tvb,offset); msg_info->cid = tvb_get_guint8(tvb,offset+4); @@ -512,7 +512,7 @@ static const gchar* dissect_fields_ceid(packet_info* pinfo _U_, tvbuff_t *tvb, p return "Path: 0 (All Paths)"; } - pi = proto_tree_add_item(tree,hf_alcap_ceid_cid,tvb,offset+4,1,FALSE); + pi = proto_tree_add_item(tree,hf_alcap_ceid_cid,tvb,offset+4,1,ENC_BIG_ENDIAN); if (msg_info->cid == 0) { proto_item_append_text(pi," (All CIDs in the Path)"); @@ -591,7 +591,7 @@ static const gchar* dissect_fields_dnsea(packet_info* pinfo _U_, tvbuff_t *tvb, msg_info->dest_nsap = tvb_bytes_to_str(tvb,offset,20); - proto_tree_add_item(tree, hf_alcap_dnsea, tvb, offset, 20, FALSE); + proto_tree_add_item(tree, hf_alcap_dnsea, tvb, offset, 20, ENC_BIG_ENDIAN); dissect_nsap(tvb, offset,20, tree); return NULL; @@ -612,7 +612,7 @@ static const gchar* dissect_fields_onsea(packet_info* pinfo _U_, tvbuff_t *tvb, msg_info->orig_nsap = tvb_bytes_to_str(tvb,offset,20); - proto_tree_add_item(tree, hf_alcap_onsea, tvb, offset, 20, FALSE); + proto_tree_add_item(tree, hf_alcap_onsea, tvb, offset, 20, ENC_BIG_ENDIAN); dissect_nsap(tvb, offset,20, tree); return NULL; @@ -634,14 +634,14 @@ static const gchar* dissect_fields_alc(packet_info* pinfo _U_, tvbuff_t *tvb, pr return NULL; } - proto_tree_add_item(tree, hf_alcap_alc_max_br_fw, tvb, offset+0, 2, FALSE); - proto_tree_add_item(tree, hf_alcap_alc_max_br_bw, tvb, offset+2, 2, FALSE); - proto_tree_add_item(tree, hf_alcap_alc_avg_br_fw, tvb, offset+4, 2, FALSE); - proto_tree_add_item(tree, hf_alcap_alc_avg_br_bw, tvb, offset+6, 2, FALSE); - proto_tree_add_item(tree, hf_alcap_alc_max_sdu_fw, tvb, offset+8, 1, FALSE); - proto_tree_add_item(tree, hf_alcap_alc_max_sdu_bw, tvb, offset+9, 1, FALSE); - proto_tree_add_item(tree, hf_alcap_alc_avg_sdu_fw, tvb, offset+10, 1, FALSE); - proto_tree_add_item(tree, hf_alcap_alc_avg_sdu_bw, tvb, offset+11, 1, FALSE); + proto_tree_add_item(tree, hf_alcap_alc_max_br_fw, tvb, offset+0, 2, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_alc_max_br_bw, tvb, offset+2, 2, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_alc_avg_br_fw, tvb, offset+4, 2, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_alc_avg_br_bw, tvb, offset+6, 2, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_alc_max_sdu_fw, tvb, offset+8, 1, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_alc_max_sdu_bw, tvb, offset+9, 1, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_alc_avg_sdu_fw, tvb, offset+10, 1, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_alc_avg_sdu_bw, tvb, offset+11, 1, ENC_BIG_ENDIAN); return NULL; } @@ -662,14 +662,14 @@ static const gchar* dissect_fields_plc(packet_info* pinfo _U_, tvbuff_t *tvb, pr return NULL; } - proto_tree_add_item(tree, hf_alcap_plc_max_br_fw, tvb, offset+0, 2, FALSE); - proto_tree_add_item(tree, hf_alcap_plc_max_br_bw, tvb, offset+2, 2, FALSE); - proto_tree_add_item(tree, hf_alcap_plc_avg_br_fw, tvb, offset+4, 2, FALSE); - proto_tree_add_item(tree, hf_alcap_plc_avg_br_bw, tvb, offset+6, 2, FALSE); - proto_tree_add_item(tree, hf_alcap_plc_max_sdu_fw, tvb, offset+8, 1, FALSE); - proto_tree_add_item(tree, hf_alcap_plc_max_sdu_bw, tvb, offset+9, 1, FALSE); - proto_tree_add_item(tree, hf_alcap_plc_avg_sdu_fw, tvb, offset+10, 1, FALSE); - proto_tree_add_item(tree, hf_alcap_plc_avg_sdu_bw, tvb, offset+11, 1, FALSE); + proto_tree_add_item(tree, hf_alcap_plc_max_br_fw, tvb, offset+0, 2, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_plc_max_br_bw, tvb, offset+2, 2, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_plc_avg_br_fw, tvb, offset+4, 2, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_plc_avg_br_bw, tvb, offset+6, 2, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_plc_max_sdu_fw, tvb, offset+8, 1, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_plc_max_sdu_bw, tvb, offset+9, 1, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_plc_avg_sdu_fw, tvb, offset+10, 1, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_plc_avg_sdu_bw, tvb, offset+11, 1, ENC_BIG_ENDIAN); return NULL; } @@ -688,7 +688,7 @@ static const gchar* dissect_fields_osaid(packet_info* pinfo _U_, tvbuff_t *tvb, msg_info->osaid = tvb_get_ntohl(tvb,offset); - proto_tree_add_item(tree, hf_alcap_osaid, tvb, offset, 4, FALSE); + proto_tree_add_item(tree, hf_alcap_osaid, tvb, offset, 4, ENC_BIG_ENDIAN); return NULL; } @@ -707,7 +707,7 @@ static const gchar* dissect_fields_sugr(packet_info* pinfo _U_, tvbuff_t *tvb, p msg_info->sugr = tvb_get_ntohl(tvb,offset); - proto_tree_add_item(tree, hf_alcap_sugr, tvb, offset, 4, FALSE); + proto_tree_add_item(tree, hf_alcap_sugr, tvb, offset, 4, ENC_BIG_ENDIAN); return NULL; } @@ -724,7 +724,7 @@ static const gchar* dissect_fields_suci(packet_info* pinfo _U_, tvbuff_t *tvb, p return NULL; } - proto_tree_add_item(tree, hf_alcap_suci, tvb, offset, len, FALSE); + proto_tree_add_item(tree, hf_alcap_suci, tvb, offset, len, ENC_BIG_ENDIAN); return NULL; } @@ -741,22 +741,22 @@ static const gchar* dissect_fields_ssia(packet_info* pinfo _U_, tvbuff_t *tvb, p return NULL; } - proto_tree_add_item(tree, hf_alcap_ssia_pr_type, tvb, offset+0,1,FALSE); + proto_tree_add_item(tree, hf_alcap_ssia_pr_type, tvb, offset+0,1,ENC_BIG_ENDIAN); - proto_tree_add_item(tree, hf_alcap_ssia_pr_id, tvb, offset+2,1,FALSE); + proto_tree_add_item(tree, hf_alcap_ssia_pr_id, tvb, offset+2,1,ENC_BIG_ENDIAN); - proto_tree_add_item(tree, hf_alcap_ssia_frm, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssia_cmd, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssia_mfr2, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssia_mfr1, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssia_dtmf, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssia_cas, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssia_fax, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssia_pcm, tvb, offset+3,1,FALSE); + proto_tree_add_item(tree, hf_alcap_ssia_frm, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssia_cmd, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssia_mfr2, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssia_mfr1, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssia_dtmf, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssia_cas, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssia_fax, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssia_pcm, tvb, offset+3,1,ENC_BIG_ENDIAN); - proto_tree_add_item(tree, hf_alcap_ssia_max_len, tvb, offset+4,2,FALSE); + proto_tree_add_item(tree, hf_alcap_ssia_max_len, tvb, offset+4,2,ENC_BIG_ENDIAN); - proto_tree_add_item(tree, hf_alcap_ssia_oui, tvb, offset+5,3,FALSE); + proto_tree_add_item(tree, hf_alcap_ssia_oui, tvb, offset+5,3,ENC_BIG_ENDIAN); return NULL; } @@ -773,9 +773,9 @@ static const gchar* dissect_fields_ssim(packet_info* pinfo _U_, tvbuff_t *tvb, p return NULL; } - proto_tree_add_item(tree,hf_alcap_ssim_frm,tvb,offset,1,FALSE); - proto_tree_add_item(tree,hf_alcap_ssim_mult,tvb,offset,1,FALSE); - proto_tree_add_item(tree,hf_alcap_ssim_max,tvb,offset+1,2,FALSE); + proto_tree_add_item(tree,hf_alcap_ssim_frm,tvb,offset,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_ssim_mult,tvb,offset,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_ssim_max,tvb,offset+1,2,ENC_BIG_ENDIAN); return NULL; } @@ -792,12 +792,12 @@ static const gchar* dissect_fields_ssisa(packet_info* pinfo _U_, tvbuff_t *tvb, return NULL; } - proto_tree_add_item(tree,hf_alcap_ssisa_max_sssar_fw,tvb,offset,3,FALSE); - proto_tree_add_item(tree,hf_alcap_ssisa_max_sssar_bw,tvb,offset+3,3,FALSE); - proto_tree_add_item(tree,hf_alcap_ssisa_max_sscop_sdu_fw,tvb,offset+6,2,FALSE); - proto_tree_add_item(tree,hf_alcap_ssisa_max_sscop_sdu_bw,tvb,offset+8,2,FALSE); - proto_tree_add_item(tree,hf_alcap_ssisa_max_sscop_uu_fw,tvb,offset+10,2,FALSE); - proto_tree_add_item(tree,hf_alcap_ssisa_max_sscop_uu_bw,tvb,offset+12,2,FALSE); + proto_tree_add_item(tree,hf_alcap_ssisa_max_sssar_fw,tvb,offset,3,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_ssisa_max_sssar_bw,tvb,offset+3,3,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_ssisa_max_sscop_sdu_fw,tvb,offset+6,2,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_ssisa_max_sscop_sdu_bw,tvb,offset+8,2,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_ssisa_max_sscop_uu_fw,tvb,offset+10,2,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_ssisa_max_sscop_uu_bw,tvb,offset+12,2,ENC_BIG_ENDIAN); proto_tree_add_text(tree,tvb,offset,14,"Not yet decoded: Q.2630.1 7.4.8"); @@ -816,9 +816,9 @@ static const gchar* dissect_fields_ssisu(packet_info* pinfo _U_, tvbuff_t *tvb, return NULL; } - proto_tree_add_item(tree,hf_alcap_ssisu_max_sssar_fw,tvb,offset,3,FALSE); - proto_tree_add_item(tree,hf_alcap_ssisu_max_sssar_bw,tvb,offset+3,3,FALSE); - proto_tree_add_item(tree,hf_alcap_ssisu_ted,tvb,offset+6,1,FALSE); + proto_tree_add_item(tree,hf_alcap_ssisu_max_sssar_fw,tvb,offset,3,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_ssisu_max_sssar_bw,tvb,offset+3,3,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_ssisu_ted,tvb,offset+6,1,ENC_BIG_ENDIAN); proto_tree_add_text(tree,tvb,offset,7,"Not yet decoded: Q.2630.1 7.4.9"); return NULL; @@ -856,25 +856,25 @@ static const gchar* dissect_fields_ssiae(packet_info* pinfo _U_, tvbuff_t *tvb, return NULL; } - proto_tree_add_item(tree, hf_alcap_ssiae_pr_type, tvb, offset,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssiae_lb, tvb, offset,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssiae_rc, tvb, offset,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssiae_syn, tvb, offset,1,FALSE); + proto_tree_add_item(tree, hf_alcap_ssiae_pr_type, tvb, offset,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssiae_lb, tvb, offset,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssiae_rc, tvb, offset,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssiae_syn, tvb, offset,1,ENC_BIG_ENDIAN); - proto_tree_add_item(tree, hf_alcap_ssiae_pr_id, tvb, offset+1,1,FALSE); + proto_tree_add_item(tree, hf_alcap_ssiae_pr_id, tvb, offset+1,1,ENC_BIG_ENDIAN); - proto_tree_add_item(tree, hf_alcap_ssiae_frm, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssiae_cmd, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssiae_mfr2, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssiae_mfr1, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssiae_dtmf, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssiae_cas, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssiae_fax, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_ssiae_pcm, tvb, offset+3,1,FALSE); + proto_tree_add_item(tree, hf_alcap_ssiae_frm, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssiae_cmd, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssiae_mfr2, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssiae_mfr1, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssiae_dtmf, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssiae_cas, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssiae_fax, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_ssiae_pcm, tvb, offset+3,1,ENC_BIG_ENDIAN); - proto_tree_add_item(tree, hf_alcap_ssiae_max_len, tvb, offset+4,2,FALSE); + proto_tree_add_item(tree, hf_alcap_ssiae_max_len, tvb, offset+4,2,ENC_BIG_ENDIAN); - proto_tree_add_item(tree, hf_alcap_ssiae_oui, tvb, offset+5,3,FALSE); + proto_tree_add_item(tree, hf_alcap_ssiae_oui, tvb, offset+5,3,ENC_BIG_ENDIAN); return NULL; } @@ -892,25 +892,25 @@ static const gchar* dissect_fields_pssiae(packet_info* pinfo _U_, tvbuff_t *tvb, return NULL; } - proto_tree_add_item(tree, hf_alcap_pssiae_pr_type, tvb, offset,1,FALSE); - proto_tree_add_item(tree, hf_alcap_pssiae_lb, tvb, offset,1,FALSE); - proto_tree_add_item(tree, hf_alcap_pssiae_rc, tvb, offset,1,FALSE); - proto_tree_add_item(tree, hf_alcap_pssiae_syn, tvb, offset,1,FALSE); + proto_tree_add_item(tree, hf_alcap_pssiae_pr_type, tvb, offset,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_pssiae_lb, tvb, offset,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_pssiae_rc, tvb, offset,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_pssiae_syn, tvb, offset,1,ENC_BIG_ENDIAN); - proto_tree_add_item(tree, hf_alcap_pssiae_pr_id, tvb, offset+1,1,FALSE); + proto_tree_add_item(tree, hf_alcap_pssiae_pr_id, tvb, offset+1,1,ENC_BIG_ENDIAN); - proto_tree_add_item(tree, hf_alcap_pssiae_frm, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_pssiae_cmd, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_pssiae_mfr2, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_pssiae_mfr1, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_pssiae_dtmf, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_pssiae_cas, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_pssiae_fax, tvb, offset+3,1,FALSE); - proto_tree_add_item(tree, hf_alcap_pssiae_pcm, tvb, offset+3,1,FALSE); + proto_tree_add_item(tree, hf_alcap_pssiae_frm, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_pssiae_cmd, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_pssiae_mfr2, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_pssiae_mfr1, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_pssiae_dtmf, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_pssiae_cas, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_pssiae_fax, tvb, offset+3,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_pssiae_pcm, tvb, offset+3,1,ENC_BIG_ENDIAN); - proto_tree_add_item(tree, hf_alcap_pssiae_max_len, tvb, offset+4,2,FALSE); + proto_tree_add_item(tree, hf_alcap_pssiae_max_len, tvb, offset+4,2,ENC_BIG_ENDIAN); - proto_tree_add_item(tree, hf_alcap_pssiae_oui, tvb, offset+5,3,FALSE); + proto_tree_add_item(tree, hf_alcap_pssiae_oui, tvb, offset+5,3,ENC_BIG_ENDIAN); return NULL; } @@ -927,10 +927,10 @@ static const gchar* dissect_fields_ssime(packet_info* pinfo _U_, tvbuff_t *tvb, return NULL; } - proto_tree_add_item(tree,hf_alcap_ssime_frm,tvb,offset,1,FALSE); - proto_tree_add_item(tree,hf_alcap_ssime_lb,tvb,offset,1,FALSE); - proto_tree_add_item(tree,hf_alcap_ssime_mult,tvb,offset,1,FALSE); - proto_tree_add_item(tree,hf_alcap_ssime_max,tvb,offset+1,2,FALSE); + proto_tree_add_item(tree,hf_alcap_ssime_frm,tvb,offset,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_ssime_lb,tvb,offset,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_ssime_mult,tvb,offset,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_ssime_max,tvb,offset+1,2,ENC_BIG_ENDIAN); return NULL; } @@ -947,10 +947,10 @@ static const gchar* dissect_fields_pssime(packet_info* pinfo _U_, tvbuff_t *tvb, return NULL; } - proto_tree_add_item(tree,hf_alcap_pssime_frm,tvb,offset,1,FALSE); - proto_tree_add_item(tree,hf_alcap_pssime_lb,tvb,offset,1,FALSE); - proto_tree_add_item(tree,hf_alcap_pssime_mult,tvb,offset,1,FALSE); - proto_tree_add_item(tree,hf_alcap_pssime_max,tvb,offset+1,2,FALSE); + proto_tree_add_item(tree,hf_alcap_pssime_frm,tvb,offset,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pssime_lb,tvb,offset,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pssime_mult,tvb,offset,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pssime_max,tvb,offset+1,2,ENC_BIG_ENDIAN); return NULL; } @@ -967,7 +967,7 @@ static const gchar* dissect_fields_acc(packet_info* pinfo _U_, tvbuff_t *tvb, pr return NULL; } - proto_tree_add_item(tree,hf_alcap_acc_level,tvb,offset,len,FALSE); + proto_tree_add_item(tree,hf_alcap_acc_level,tvb,offset,len,ENC_BIG_ENDIAN); return NULL; } @@ -984,7 +984,7 @@ static const gchar* dissect_fields_cp(packet_info* pinfo _U_, tvbuff_t *tvb, pro return NULL; } - proto_tree_add_item(tree,hf_alcap_cp,tvb,offset,len,FALSE); + proto_tree_add_item(tree,hf_alcap_cp,tvb,offset,len,ENC_BIG_ENDIAN); return NULL; } @@ -1000,7 +1000,7 @@ static const gchar* dissect_fields_pt(packet_info* pinfo _U_, tvbuff_t *tvb, pro return NULL; } - proto_tree_add_item(tree,hf_alcap_pt,tvb,offset,len,FALSE); + proto_tree_add_item(tree,hf_alcap_pt,tvb,offset,len,ENC_BIG_ENDIAN); return NULL; } @@ -1017,7 +1017,7 @@ static const gchar* dissect_fields_hc(packet_info* pinfo _U_, tvbuff_t *tvb, pro return NULL; } - proto_tree_add_item(tree,hf_alcap_hc,tvb,offset,len,FALSE); + proto_tree_add_item(tree,hf_alcap_hc,tvb,offset,len,ENC_BIG_ENDIAN); return NULL; } @@ -1036,12 +1036,12 @@ static const gchar* dissect_fields_fbw(packet_info* pinfo _U_, tvbuff_t *tvb, pr return NULL; } - proto_tree_add_item(tree,hf_alcap_fbw_br_fw,tvb,offset,3,FALSE); - proto_tree_add_item(tree,hf_alcap_fbw_br_bw,tvb,offset+3,3,FALSE); - proto_tree_add_item(tree,hf_alcap_fbw_bucket_fw,tvb,offset+6,2,FALSE); - proto_tree_add_item(tree,hf_alcap_fbw_bucket_bw,tvb,offset+8,2,FALSE); - proto_tree_add_item(tree,hf_alcap_fbw_size_fw,tvb,offset+10,1,FALSE); - proto_tree_add_item(tree,hf_alcap_fbw_size_bw,tvb,offset+11,1,FALSE); + proto_tree_add_item(tree,hf_alcap_fbw_br_fw,tvb,offset,3,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_fbw_br_bw,tvb,offset+3,3,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_fbw_bucket_fw,tvb,offset+6,2,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_fbw_bucket_bw,tvb,offset+8,2,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_fbw_size_fw,tvb,offset+10,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_fbw_size_bw,tvb,offset+11,1,ENC_BIG_ENDIAN); return NULL; } @@ -1060,12 +1060,12 @@ static const gchar* dissect_fields_pfbw(packet_info* pinfo _U_, tvbuff_t *tvb, p return NULL; } - proto_tree_add_item(tree,hf_alcap_pfbw_br_fw,tvb,offset,3,FALSE); - proto_tree_add_item(tree,hf_alcap_pfbw_br_bw,tvb,offset+3,3,FALSE); - proto_tree_add_item(tree,hf_alcap_pfbw_bucket_fw,tvb,offset+6,2,FALSE); - proto_tree_add_item(tree,hf_alcap_pfbw_bucket_bw,tvb,offset+8,2,FALSE); - proto_tree_add_item(tree,hf_alcap_pfbw_size_fw,tvb,offset+10,1,FALSE); - proto_tree_add_item(tree,hf_alcap_pfbw_size_bw,tvb,offset+11,1,FALSE); + proto_tree_add_item(tree,hf_alcap_pfbw_br_fw,tvb,offset,3,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pfbw_br_bw,tvb,offset+3,3,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pfbw_bucket_fw,tvb,offset+6,2,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pfbw_bucket_bw,tvb,offset+8,2,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pfbw_size_fw,tvb,offset+10,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pfbw_size_bw,tvb,offset+11,1,ENC_BIG_ENDIAN); return NULL; } @@ -1085,14 +1085,14 @@ static const gchar* dissect_fields_vbws(packet_info* pinfo _U_, tvbuff_t *tvb, p return NULL; } - proto_tree_add_item(tree,hf_alcap_vbws_br_fw,tvb,offset,3,FALSE); - proto_tree_add_item(tree,hf_alcap_vbws_br_bw,tvb,offset+3,3,FALSE); - proto_tree_add_item(tree,hf_alcap_vbws_bucket_fw,tvb,offset+6,2,FALSE); - proto_tree_add_item(tree,hf_alcap_vbws_bucket_bw,tvb,offset+8,2,FALSE); - proto_tree_add_item(tree,hf_alcap_vbws_size_fw,tvb,offset+10,1,FALSE); - proto_tree_add_item(tree,hf_alcap_vbws_size_bw,tvb,offset+11,1,FALSE); - proto_tree_add_item(tree,hf_alcap_vbws_size_bw,tvb,offset+11,1,FALSE); - proto_tree_add_item(tree,hf_alcap_vbws_stt,tvb,offset+12,1,FALSE); + proto_tree_add_item(tree,hf_alcap_vbws_br_fw,tvb,offset,3,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_vbws_br_bw,tvb,offset+3,3,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_vbws_bucket_fw,tvb,offset+6,2,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_vbws_bucket_bw,tvb,offset+8,2,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_vbws_size_fw,tvb,offset+10,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_vbws_size_bw,tvb,offset+11,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_vbws_size_bw,tvb,offset+11,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_vbws_stt,tvb,offset+12,1,ENC_BIG_ENDIAN); return NULL; } @@ -1112,14 +1112,14 @@ static const gchar* dissect_fields_pvbws(packet_info* pinfo _U_, tvbuff_t *tvb, return NULL; } - proto_tree_add_item(tree,hf_alcap_pvbws_br_fw,tvb,offset,3,FALSE); - proto_tree_add_item(tree,hf_alcap_pvbws_br_bw,tvb,offset+3,3,FALSE); - proto_tree_add_item(tree,hf_alcap_pvbws_bucket_fw,tvb,offset+6,2,FALSE); - proto_tree_add_item(tree,hf_alcap_pvbws_bucket_bw,tvb,offset+8,2,FALSE); - proto_tree_add_item(tree,hf_alcap_pvbws_size_fw,tvb,offset+10,1,FALSE); - proto_tree_add_item(tree,hf_alcap_pvbws_size_bw,tvb,offset+11,1,FALSE); - proto_tree_add_item(tree,hf_alcap_pvbws_size_bw,tvb,offset+11,1,FALSE); - proto_tree_add_item(tree,hf_alcap_pvbws_stt,tvb,offset+12,1,FALSE); + proto_tree_add_item(tree,hf_alcap_pvbws_br_fw,tvb,offset,3,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pvbws_br_bw,tvb,offset+3,3,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pvbws_bucket_fw,tvb,offset+6,2,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pvbws_bucket_bw,tvb,offset+8,2,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pvbws_size_fw,tvb,offset+10,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pvbws_size_bw,tvb,offset+11,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pvbws_size_bw,tvb,offset+11,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pvbws_stt,tvb,offset+12,1,ENC_BIG_ENDIAN); return NULL; } @@ -1142,20 +1142,20 @@ static const gchar* dissect_fields_pvbwt(packet_info* pinfo _U_, tvbuff_t *tvb, return NULL; } - proto_tree_add_item(tree,hf_alcap_pvbwt_peak_br_fw,tvb,offset,3,FALSE); - proto_tree_add_item(tree,hf_alcap_pvbwt_peak_br_bw,tvb,offset+3,3,FALSE); + proto_tree_add_item(tree,hf_alcap_pvbwt_peak_br_fw,tvb,offset,3,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pvbwt_peak_br_bw,tvb,offset+3,3,ENC_BIG_ENDIAN); - proto_tree_add_item(tree,hf_alcap_pvbwt_peak_bucket_fw,tvb,offset+6,2,FALSE); - proto_tree_add_item(tree,hf_alcap_pvbwt_peak_bucket_bw,tvb,offset+8,2,FALSE); + proto_tree_add_item(tree,hf_alcap_pvbwt_peak_bucket_fw,tvb,offset+6,2,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pvbwt_peak_bucket_bw,tvb,offset+8,2,ENC_BIG_ENDIAN); - proto_tree_add_item(tree,hf_alcap_pvbwt_sust_br_fw,tvb,offset+10,3,FALSE); - proto_tree_add_item(tree,hf_alcap_pvbwt_sust_br_bw,tvb,offset+13,3,FALSE); + proto_tree_add_item(tree,hf_alcap_pvbwt_sust_br_fw,tvb,offset+10,3,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pvbwt_sust_br_bw,tvb,offset+13,3,ENC_BIG_ENDIAN); - proto_tree_add_item(tree,hf_alcap_pvbwt_sust_bucket_fw,tvb,offset+16,2,FALSE); - proto_tree_add_item(tree,hf_alcap_pvbwt_sust_bucket_bw,tvb,offset+18,2,FALSE); + proto_tree_add_item(tree,hf_alcap_pvbwt_sust_bucket_fw,tvb,offset+16,2,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pvbwt_sust_bucket_bw,tvb,offset+18,2,ENC_BIG_ENDIAN); - proto_tree_add_item(tree,hf_alcap_pvbwt_size_fw,tvb,offset+20,1,FALSE); - proto_tree_add_item(tree,hf_alcap_pvbwt_size_bw,tvb,offset+21,1,FALSE); + proto_tree_add_item(tree,hf_alcap_pvbwt_size_fw,tvb,offset+20,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_pvbwt_size_bw,tvb,offset+21,1,ENC_BIG_ENDIAN); return NULL; } @@ -1176,20 +1176,20 @@ static const gchar* dissect_fields_vbwt(packet_info* pinfo _U_, tvbuff_t *tvb, p return NULL; } - proto_tree_add_item(tree,hf_alcap_vbwt_peak_br_fw,tvb,offset,3,FALSE); - proto_tree_add_item(tree,hf_alcap_vbwt_peak_br_bw,tvb,offset+3,3,FALSE); + proto_tree_add_item(tree,hf_alcap_vbwt_peak_br_fw,tvb,offset,3,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_vbwt_peak_br_bw,tvb,offset+3,3,ENC_BIG_ENDIAN); - proto_tree_add_item(tree,hf_alcap_vbwt_peak_bucket_fw,tvb,offset+6,2,FALSE); - proto_tree_add_item(tree,hf_alcap_vbwt_peak_bucket_bw,tvb,offset+8,2,FALSE); + proto_tree_add_item(tree,hf_alcap_vbwt_peak_bucket_fw,tvb,offset+6,2,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_vbwt_peak_bucket_bw,tvb,offset+8,2,ENC_BIG_ENDIAN); - proto_tree_add_item(tree,hf_alcap_vbwt_sust_br_fw,tvb,offset+10,3,FALSE); - proto_tree_add_item(tree,hf_alcap_vbwt_sust_br_bw,tvb,offset+13,3,FALSE); + proto_tree_add_item(tree,hf_alcap_vbwt_sust_br_fw,tvb,offset+10,3,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_vbwt_sust_br_bw,tvb,offset+13,3,ENC_BIG_ENDIAN); - proto_tree_add_item(tree,hf_alcap_vbwt_sust_bucket_fw,tvb,offset+16,2,FALSE); - proto_tree_add_item(tree,hf_alcap_vbwt_sust_bucket_bw,tvb,offset+18,2,FALSE); + proto_tree_add_item(tree,hf_alcap_vbwt_sust_bucket_fw,tvb,offset+16,2,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_vbwt_sust_bucket_bw,tvb,offset+18,2,ENC_BIG_ENDIAN); - proto_tree_add_item(tree,hf_alcap_vbwt_size_fw,tvb,offset+20,1,FALSE); - proto_tree_add_item(tree,hf_alcap_vbwt_size_bw,tvb,offset+21,1,FALSE); + proto_tree_add_item(tree,hf_alcap_vbwt_size_fw,tvb,offset+20,1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree,hf_alcap_vbwt_size_bw,tvb,offset+21,1,ENC_BIG_ENDIAN); return NULL; } @@ -1210,8 +1210,8 @@ static const gchar* dissect_fields_sut(packet_info* pinfo _U_, tvbuff_t *tvb, pr sut_len = tvb_get_guint8(tvb,offset); - proto_tree_add_item(tree, hf_alcap_sut_len, tvb, offset, 1, FALSE); - proto_tree_add_item(tree, hf_alcap_sut, tvb, offset, sut_len, FALSE); + proto_tree_add_item(tree, hf_alcap_sut_len, tvb, offset, 1, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_alcap_sut, tvb, offset, sut_len, ENC_BIG_ENDIAN); return NULL; } @@ -1375,12 +1375,12 @@ static void dissect_alcap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) { col_set_str(pinfo->cinfo, COL_PROTOCOL, alcap_proto_name_short); if (tree) { - proto_item *alcap_item = proto_tree_add_item(tree, proto_alcap, tvb, 0, -1, FALSE); + proto_item *alcap_item = proto_tree_add_item(tree, proto_alcap, tvb, 0, -1, ENC_BIG_ENDIAN); alcap_tree = proto_item_add_subtree(alcap_item, ett_alcap); } - proto_tree_add_item(alcap_tree,hf_alcap_dsaid,tvb,0,4,FALSE); - pi = proto_tree_add_item(alcap_tree,hf_alcap_msg_id,tvb,4,1,FALSE); + proto_tree_add_item(alcap_tree,hf_alcap_dsaid,tvb,0,4,ENC_BIG_ENDIAN); + pi = proto_tree_add_item(alcap_tree,hf_alcap_msg_id,tvb,4,1,ENC_BIG_ENDIAN); msg_info->dsaid = tvb_get_ntohl(tvb, 0); msg_info->msg_type = tvb_get_guint8(tvb, 4); @@ -1391,12 +1391,12 @@ static void dissect_alcap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) { col_set_str(pinfo->cinfo, COL_INFO, msg_type->abbr); - pi = proto_tree_add_item(alcap_tree,hf_alcap_compat,tvb,5,1,FALSE); + pi = proto_tree_add_item(alcap_tree,hf_alcap_compat,tvb,5,1,ENC_BIG_ENDIAN); compat_tree = proto_item_add_subtree(pi,ett_compat); - proto_tree_add_item(compat_tree,hf_alcap_compat_pass_on_sni,tvb,5,1,FALSE); - proto_tree_add_item(compat_tree,hf_alcap_compat_pass_on_ii,tvb,5,1,FALSE); - proto_tree_add_item(compat_tree,hf_alcap_compat_general_sni,tvb,5,1,FALSE); - proto_tree_add_item(compat_tree,hf_alcap_compat_general_ii,tvb,5,1,FALSE); + proto_tree_add_item(compat_tree,hf_alcap_compat_pass_on_sni,tvb,5,1,ENC_BIG_ENDIAN); + proto_tree_add_item(compat_tree,hf_alcap_compat_pass_on_ii,tvb,5,1,ENC_BIG_ENDIAN); + proto_tree_add_item(compat_tree,hf_alcap_compat_general_sni,tvb,5,1,ENC_BIG_ENDIAN); + proto_tree_add_item(compat_tree,hf_alcap_compat_general_ii,tvb,5,1,ENC_BIG_ENDIAN); len -= ALCAP_MSG_HEADER_LEN; offset = ALCAP_MSG_HEADER_LEN; @@ -1408,24 +1408,22 @@ static void dissect_alcap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) { proto_tree* param_tree; const gchar* colinfo_str = NULL; - pi = proto_tree_add_item(alcap_tree,hf_alcap_param_id,tvb,offset,1,FALSE); + pi = proto_tree_add_item(alcap_tree,hf_alcap_param_id,tvb,offset,1,ENC_BIG_ENDIAN); param_tree = proto_item_add_subtree(pi,param_info->ett); - pi = proto_tree_add_item(param_tree,hf_alcap_compat,tvb,offset+1,1,FALSE); + pi = proto_tree_add_item(param_tree,hf_alcap_compat,tvb,offset+1,1,ENC_BIG_ENDIAN); compat_tree = proto_item_add_subtree(pi,ett_compat); - proto_tree_add_item(compat_tree,hf_alcap_compat_pass_on_sni,tvb,offset+1,1,FALSE); - proto_tree_add_item(compat_tree,hf_alcap_compat_pass_on_ii,tvb,offset+1,1,FALSE); - proto_tree_add_item(compat_tree,hf_alcap_compat_general_sni,tvb,offset+1,1,FALSE); - proto_tree_add_item(compat_tree,hf_alcap_compat_general_ii,tvb,offset+1,1,FALSE); + proto_tree_add_item(compat_tree,hf_alcap_compat_pass_on_sni,tvb,offset+1,1,ENC_BIG_ENDIAN); + proto_tree_add_item(compat_tree,hf_alcap_compat_pass_on_ii,tvb,offset+1,1,ENC_BIG_ENDIAN); + proto_tree_add_item(compat_tree,hf_alcap_compat_general_sni,tvb,offset+1,1,ENC_BIG_ENDIAN); + proto_tree_add_item(compat_tree,hf_alcap_compat_general_ii,tvb,offset+1,1,ENC_BIG_ENDIAN); - proto_tree_add_item(param_tree,hf_alcap_param_len,tvb,offset+2,1,FALSE); + proto_tree_add_item(param_tree,hf_alcap_param_len,tvb,offset+2,1,ENC_BIG_ENDIAN); if ( alcap_tree || param_info->run_wo_tree ) colinfo_str = param_info->dissect_fields(pinfo,tvb,param_tree,offset+3,param_len,msg_info); - if (colinfo_str && check_col(pinfo->cinfo, COL_INFO)) { - col_append_fstr(pinfo->cinfo, COL_INFO, " %s",colinfo_str); - } + col_append_fstr(pinfo->cinfo, COL_INFO, " %s",colinfo_str); len -= 3 + param_len; offset += 3 + param_len; diff --git a/epan/dissectors/packet-ans.c b/epan/dissectors/packet-ans.c index 44a34c3019..ded5187531 100644 --- a/epan/dissectors/packet-ans.c +++ b/epan/dissectors/packet-ans.c @@ -76,24 +76,22 @@ dissect_ans(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) col_set_str(pinfo->cinfo, COL_PROTOCOL, "Intel ANS probe"); - if (check_col(pinfo->cinfo, COL_INFO)) { - seq_num = tvb_get_ntohl(tvb, 4); - sender_id = tvb_get_ntohs(tvb, 8); - tvb_memcpy(tvb, team_id, 10, 6); + seq_num = tvb_get_ntohl(tvb, 4); + sender_id = tvb_get_ntohs(tvb, 8); + tvb_memcpy(tvb, team_id, 10, 6); - col_add_fstr(pinfo->cinfo, COL_INFO, "Sequence: %u, Sender ID %u, Team ID %s", - seq_num, sender_id, ether_to_str(team_id)); - } + col_add_fstr(pinfo->cinfo, COL_INFO, "Sequence: %u, Sender ID %u, Team ID %s", + seq_num, sender_id, ether_to_str(team_id)); if (tree) { - ti = proto_tree_add_item(tree, proto_ans, tvb, 0, -1, FALSE); + ti = proto_tree_add_item(tree, proto_ans, tvb, 0, -1, ENC_BIG_ENDIAN); ans_tree = proto_item_add_subtree(ti, ett_ans); - proto_tree_add_item(ans_tree, hf_ans_app_id, tvb, 0, 2, FALSE); - proto_tree_add_item(ans_tree, hf_ans_rev_id, tvb, 2, 2, FALSE); - proto_tree_add_item(ans_tree, hf_ans_seq_num, tvb, 4, 4, FALSE); - proto_tree_add_item(ans_tree, hf_ans_sender_id, tvb, 8, 2, FALSE); - proto_tree_add_item(ans_tree, hf_ans_team_id, tvb, 10, 6, FALSE); + proto_tree_add_item(ans_tree, hf_ans_app_id, tvb, 0, 2, ENC_BIG_ENDIAN); + proto_tree_add_item(ans_tree, hf_ans_rev_id, tvb, 2, 2, ENC_BIG_ENDIAN); + proto_tree_add_item(ans_tree, hf_ans_seq_num, tvb, 4, 4, ENC_BIG_ENDIAN); + proto_tree_add_item(ans_tree, hf_ans_sender_id, tvb, 8, 2, ENC_BIG_ENDIAN); + proto_tree_add_item(ans_tree, hf_ans_team_id, tvb, 10, 6, ENC_BIG_ENDIAN); } } diff --git a/epan/dissectors/packet-aodv.c b/epan/dissectors/packet-aodv.c index d3fcb7c985..9aa70adab8 100644 --- a/epan/dissectors/packet-aodv.c +++ b/epan/dissectors/packet-aodv.c @@ -171,9 +171,9 @@ dissect_aodv_ext(tvbuff_t * tvb, int offset, proto_tree * tree) val_to_str(type, exttype_vals, "Unknown")); if (len == 0) { - proto_tree_add_text(ext_tree, tvb, offset + 1, 1, - "Invalid option length: %u", len); - return; /* we must not try to decode this */ + proto_tree_add_text(ext_tree, tvb, offset + 1, 1, + "Invalid option length: %u", len); + return; /* we must not try to decode this */ } proto_tree_add_text(ext_tree, tvb, offset + 1, 1, "Length: %u bytes", len); @@ -182,15 +182,15 @@ dissect_aodv_ext(tvbuff_t * tvb, int offset, proto_tree * tree) switch (type) { case AODV_EXT_INT: - proto_tree_add_uint(ext_tree, hf_aodv_ext_interval, - tvb, offset, 4, tvb_get_ntohl(tvb, offset)); + proto_tree_add_uint(ext_tree, hf_aodv_ext_interval, + tvb, offset, 4, tvb_get_ntohl(tvb, offset)); break; case AODV_EXT_NTP: - proto_tree_add_item(ext_tree, hf_aodv_ext_timestamp, - tvb, offset, 8, FALSE); - break; - default: - break; + proto_tree_add_item(ext_tree, hf_aodv_ext_timestamp, + tvb, offset, 8, ENC_BIG_ENDIAN); + break; + default: + break; } /* If multifield extensions appear, we need more * sophisticated handler. For now, this is okay. */ @@ -252,40 +252,38 @@ dissect_aodv_rreq(tvbuff_t *tvb, packet_info *pinfo, proto_tree *aodv_tree, rreq_id = tvb_get_ntohl(tvb, offset); if (aodv_tree) - proto_tree_add_uint(aodv_tree, hf_aodv_rreq_id, tvb, offset, 4, - rreq_id); + proto_tree_add_uint(aodv_tree, hf_aodv_rreq_id, tvb, offset, 4, + rreq_id); offset += 4; if (is_ipv6) { - tvb_get_ipv6(tvb, offset, &dest_addr_v6); - if (aodv_tree) { - proto_tree_add_ipv6(aodv_tree, hf_aodv_dest_ipv6, tvb, offset, - INET6_ADDRLEN, (guint8 *)&dest_addr_v6); - proto_item_append_text(ti, ", Dest IP: %s", - ip6_to_str(&dest_addr_v6)); - } - if (check_col(pinfo->cinfo, COL_INFO)) - col_append_fstr(pinfo->cinfo, COL_INFO, ", D: %s", - ip6_to_str(&dest_addr_v6)); - offset += INET6_ADDRLEN; + tvb_get_ipv6(tvb, offset, &dest_addr_v6); + if (aodv_tree) { + proto_tree_add_ipv6(aodv_tree, hf_aodv_dest_ipv6, tvb, offset, + INET6_ADDRLEN, (guint8 *)&dest_addr_v6); + proto_item_append_text(ti, ", Dest IP: %s", + ip6_to_str(&dest_addr_v6)); + } + col_append_fstr(pinfo->cinfo, COL_INFO, ", D: %s", + ip6_to_str(&dest_addr_v6)); + offset += INET6_ADDRLEN; } else { - dest_addr_v4 = tvb_get_ipv4(tvb, offset); - if (aodv_tree) { - proto_tree_add_ipv4(aodv_tree, hf_aodv_dest_ip, tvb, offset, 4, - dest_addr_v4); - proto_item_append_text(ti, ", Dest IP: %s", - ip_to_str((guint8 *)&dest_addr_v4)); - } - if (check_col(pinfo->cinfo, COL_INFO)) - col_append_fstr(pinfo->cinfo, COL_INFO, ", D: %s", - ip_to_str((guint8 *)&dest_addr_v4)); - offset += 4; + dest_addr_v4 = tvb_get_ipv4(tvb, offset); + if (aodv_tree) { + proto_tree_add_ipv4(aodv_tree, hf_aodv_dest_ip, tvb, offset, 4, + dest_addr_v4); + proto_item_append_text(ti, ", Dest IP: %s", + ip_to_str((guint8 *)&dest_addr_v4)); + } + col_append_fstr(pinfo->cinfo, COL_INFO, ", D: %s", + ip_to_str((guint8 *)&dest_addr_v4)); + offset += 4; } dest_seqno = tvb_get_ntohl(tvb, offset); if (aodv_tree) - proto_tree_add_uint(aodv_tree, hf_aodv_dest_seqno, tvb, offset, 4, - dest_seqno); + proto_tree_add_uint(aodv_tree, hf_aodv_dest_seqno, tvb, offset, 4, + dest_seqno); offset += 4; if (is_ipv6) { @@ -296,9 +294,8 @@ dissect_aodv_rreq(tvbuff_t *tvb, packet_info *pinfo, proto_tree *aodv_tree, proto_item_append_text(ti, ", Orig IP: %s", ip6_to_str(&orig_addr_v6)); } - if (check_col(pinfo->cinfo, COL_INFO)) - col_append_fstr(pinfo->cinfo, COL_INFO, ", O: %s", - ip6_to_str(&orig_addr_v6)); + col_append_fstr(pinfo->cinfo, COL_INFO, ", O: %s", + ip6_to_str(&orig_addr_v6)); offset += INET6_ADDRLEN; } else { orig_addr_v4 = tvb_get_ipv4(tvb, offset); @@ -308,17 +305,15 @@ dissect_aodv_rreq(tvbuff_t *tvb, packet_info *pinfo, proto_tree *aodv_tree, proto_item_append_text(ti, ", Orig IP: %s", ip_to_str((guint8 *)&orig_addr_v4)); } - if (check_col(pinfo->cinfo, COL_INFO)) - col_append_fstr(pinfo->cinfo, COL_INFO, ", O: %s", - ip_to_str((guint8 *)&orig_addr_v4)); + col_append_fstr(pinfo->cinfo, COL_INFO, ", O: %s", + ip_to_str((guint8 *)&orig_addr_v4)); offset += 4; } orig_seqno = tvb_get_ntohl(tvb, offset); if (aodv_tree) - proto_tree_add_uint(aodv_tree, hf_aodv_orig_seqno, tvb, offset, 4, - orig_seqno); - if (check_col(pinfo->cinfo, COL_INFO)) + proto_tree_add_uint(aodv_tree, hf_aodv_orig_seqno, tvb, offset, 4, + orig_seqno); col_append_fstr(pinfo->cinfo, COL_INFO, " Id=%u Hcnt=%u DSN=%u OSN=%u", rreq_id, hop_count, @@ -327,7 +322,7 @@ dissect_aodv_rreq(tvbuff_t *tvb, packet_info *pinfo, proto_tree *aodv_tree, offset += 4; if (aodv_tree) { - extlen = tvb_reported_length_remaining(tvb, offset); + extlen = tvb_reported_length_remaining(tvb, offset); if (extlen > 0) dissect_aodv_ext(tvb, offset, aodv_tree); } @@ -379,70 +374,67 @@ dissect_aodv_rrep(tvbuff_t *tvb, packet_info *pinfo, proto_tree *aodv_tree, offset += 1; if (is_ipv6) { - tvb_get_ipv6(tvb, offset, &dest_addr_v6); - if (aodv_tree) { - proto_tree_add_ipv6(aodv_tree, hf_aodv_dest_ipv6, tvb, offset, - INET6_ADDRLEN, (guint8 *)&dest_addr_v6); - proto_item_append_text(ti, ", Dest IP: %s", - ip6_to_str(&dest_addr_v6)); - } - if (check_col(pinfo->cinfo, COL_INFO)) - col_append_fstr(pinfo->cinfo, COL_INFO, ", D: %s", - ip6_to_str(&dest_addr_v6)); - offset += INET6_ADDRLEN; + tvb_get_ipv6(tvb, offset, &dest_addr_v6); + if (aodv_tree) { + proto_tree_add_ipv6(aodv_tree, hf_aodv_dest_ipv6, tvb, offset, + INET6_ADDRLEN, (guint8 *)&dest_addr_v6); + proto_item_append_text(ti, ", Dest IP: %s", + ip6_to_str(&dest_addr_v6)); + } + + col_append_fstr(pinfo->cinfo, COL_INFO, ", D: %s", + ip6_to_str(&dest_addr_v6)); + offset += INET6_ADDRLEN; } else { - dest_addr_v4 = tvb_get_ipv4(tvb, offset); - if (aodv_tree) { - proto_tree_add_ipv4(aodv_tree, hf_aodv_dest_ip, tvb, offset, 4, - dest_addr_v4); - proto_item_append_text(ti, ", Dest IP: %s", - ip_to_str((guint8 *)&dest_addr_v4)); - } - if (check_col(pinfo->cinfo, COL_INFO)) - col_append_fstr(pinfo->cinfo, COL_INFO, ", D: %s", - ip_to_str((guint8 *)&dest_addr_v4)); - offset += 4; + dest_addr_v4 = tvb_get_ipv4(tvb, offset); + if (aodv_tree) { + proto_tree_add_ipv4(aodv_tree, hf_aodv_dest_ip, tvb, offset, 4, + dest_addr_v4); + proto_item_append_text(ti, ", Dest IP: %s", + ip_to_str((guint8 *)&dest_addr_v4)); + } + col_append_fstr(pinfo->cinfo, COL_INFO, ", D: %s", + ip_to_str((guint8 *)&dest_addr_v4)); + offset += 4; } dest_seqno = tvb_get_ntohl(tvb, offset); if (aodv_tree) - proto_tree_add_uint(aodv_tree, hf_aodv_dest_seqno, tvb, offset, 4, - dest_seqno); + proto_tree_add_uint(aodv_tree, hf_aodv_dest_seqno, tvb, offset, 4, + dest_seqno); offset += 4; if (is_ipv6) { - tvb_get_ipv6(tvb, offset, &orig_addr_v6); - if (aodv_tree) { - proto_tree_add_ipv6(aodv_tree, hf_aodv_orig_ipv6, tvb, offset, - INET6_ADDRLEN, (guint8 *)&orig_addr_v6); - proto_item_append_text(ti, ", Orig IP: %s", - ip6_to_str(&orig_addr_v6)); - } - if (check_col(pinfo->cinfo, COL_INFO)) - col_append_fstr(pinfo->cinfo, COL_INFO, ", O: %s", - ip6_to_str(&orig_addr_v6)); - offset += INET6_ADDRLEN; + tvb_get_ipv6(tvb, offset, &orig_addr_v6); + if (aodv_tree) { + proto_tree_add_ipv6(aodv_tree, hf_aodv_orig_ipv6, tvb, offset, + INET6_ADDRLEN, (guint8 *)&orig_addr_v6); + proto_item_append_text(ti, ", Orig IP: %s", + ip6_to_str(&orig_addr_v6)); + } + col_append_fstr(pinfo->cinfo, COL_INFO, ", O: %s", + ip6_to_str(&orig_addr_v6)); + offset += INET6_ADDRLEN; } else { - orig_addr_v4 = tvb_get_ipv4(tvb, offset); - if (aodv_tree) { - proto_tree_add_ipv4(aodv_tree, hf_aodv_orig_ip, tvb, offset, 4, - orig_addr_v4); - proto_item_append_text(ti, ", Orig IP: %s", - ip_to_str((guint8 *)&orig_addr_v4)); - } - if (check_col(pinfo->cinfo, COL_INFO)) - col_append_fstr(pinfo->cinfo, COL_INFO, ", O: %s", - ip_to_str((guint8 *)&orig_addr_v4)); - offset += 4; + orig_addr_v4 = tvb_get_ipv4(tvb, offset); + if (aodv_tree) { + proto_tree_add_ipv4(aodv_tree, hf_aodv_orig_ip, tvb, offset, 4, + orig_addr_v4); + proto_item_append_text(ti, ", Orig IP: %s", + ip_to_str((guint8 *)&orig_addr_v4)); + } + col_append_fstr(pinfo->cinfo, COL_INFO, ", O: %s", + ip_to_str((guint8 *)&orig_addr_v4)); + offset += 4; } lifetime = tvb_get_ntohl(tvb, offset); if (aodv_tree) { - proto_tree_add_uint(aodv_tree, hf_aodv_lifetime, tvb, offset, 4, - lifetime); - proto_item_append_text(ti, ", Lifetime=%u", lifetime); + proto_tree_add_uint(aodv_tree, hf_aodv_lifetime, tvb, offset, 4, + lifetime); + proto_item_append_text(ti, ", Lifetime=%u", lifetime); } - if (check_col(pinfo->cinfo, COL_INFO)) + col_append_fstr(pinfo->cinfo, COL_INFO, " Hcnt=%u DSN=%u Lifetime=%u", hop_count, dest_seqno, @@ -483,7 +475,6 @@ dissect_aodv_rerr(tvbuff_t *tvb, packet_info *pinfo, proto_tree *aodv_tree, if (aodv_tree) proto_tree_add_uint(aodv_tree, hf_aodv_destcount, tvb, offset, 1, dest_count); - if (check_col(pinfo->cinfo, COL_INFO)) col_append_fstr(pinfo->cinfo, COL_INFO, ", Dest Count=%u", dest_count); offset += 1; @@ -496,10 +487,10 @@ dissect_aodv_rerr(tvbuff_t *tvb, packet_info *pinfo, proto_tree *aodv_tree, for (i = 0; i < dest_count; i++) { proto_tree_add_item(aodv_unreach_dest_tree, hf_aodv_unreach_dest_ipv6, - tvb, offset, INET6_ADDRLEN, FALSE); + tvb, offset, INET6_ADDRLEN, ENC_BIG_ENDIAN); offset += INET6_ADDRLEN; proto_tree_add_item(aodv_unreach_dest_tree, hf_aodv_dest_seqno, - tvb, offset, 4, FALSE); + tvb, offset, 4, ENC_BIG_ENDIAN); offset += 4; } } else { @@ -508,10 +499,10 @@ dissect_aodv_rerr(tvbuff_t *tvb, packet_info *pinfo, proto_tree *aodv_tree, aodv_unreach_dest_tree = proto_item_add_subtree(tj, ett_aodv_unreach_dest); for (i = 0; i < dest_count; i++) { proto_tree_add_item(aodv_unreach_dest_tree, hf_aodv_unreach_dest_ip, - tvb, offset, 4, FALSE); + tvb, offset, 4, ENC_BIG_ENDIAN); offset += 4; proto_tree_add_item(aodv_unreach_dest_tree, hf_aodv_dest_seqno, - tvb, offset, 4, FALSE); + tvb, offset, 4, ENC_BIG_ENDIAN); offset += 4; } } @@ -591,7 +582,7 @@ dissect_aodv_draft_01_v6_rreq(tvbuff_t *tvb, packet_info *pinfo, proto_item_append_text(ti, ", Dest IP: %s", ip6_to_str(&dest_addr_v6)); } - if (check_col(pinfo->cinfo, COL_INFO)) + col_append_fstr(pinfo->cinfo, COL_INFO, ", D: %s", ip6_to_str(&dest_addr_v6)); offset += INET6_ADDRLEN; @@ -603,7 +594,7 @@ dissect_aodv_draft_01_v6_rreq(tvbuff_t *tvb, packet_info *pinfo, proto_item_append_text(ti, ", Orig IP: %s", ip6_to_str(&orig_addr_v6)); } - if (check_col(pinfo->cinfo, COL_INFO)) + col_append_fstr(pinfo->cinfo, COL_INFO, ", O: %s Id=%u Hcnt=%u DSN=%u OSN=%u", ip6_to_str(&orig_addr_v6), @@ -676,7 +667,7 @@ dissect_aodv_draft_01_v6_rrep(tvbuff_t *tvb, packet_info *pinfo, proto_item_append_text(ti, ", Dest IP: %s", ip6_to_str(&dest_addr_v6)); } - if (check_col(pinfo->cinfo, COL_INFO)) + col_append_fstr(pinfo->cinfo, COL_INFO, ", D: %s", ip6_to_str(&dest_addr_v6)); offset += INET6_ADDRLEN; @@ -688,7 +679,7 @@ dissect_aodv_draft_01_v6_rrep(tvbuff_t *tvb, packet_info *pinfo, proto_item_append_text(ti, ", Orig IP: %s", ip6_to_str(&orig_addr_v6)); } - if (check_col(pinfo->cinfo, COL_INFO)) + col_append_fstr(pinfo->cinfo, COL_INFO, ", O: %s", ip6_to_str(&orig_addr_v6)); offset += INET6_ADDRLEN; @@ -699,7 +690,7 @@ dissect_aodv_draft_01_v6_rrep(tvbuff_t *tvb, packet_info *pinfo, lifetime); proto_item_append_text(ti, ", Lifetime=%u", lifetime); } - if (check_col(pinfo->cinfo, COL_INFO)) + col_append_fstr(pinfo->cinfo, COL_INFO, " Hcnt=%u DSN=%u Lifetime=%u", hop_count, dest_seqno, @@ -740,7 +731,7 @@ dissect_aodv_draft_01_v6_rerr(tvbuff_t *tvb, packet_info *pinfo, if (aodv_tree) proto_tree_add_uint(aodv_tree, hf_aodv_destcount, tvb, offset, 1, dest_count); - if (check_col(pinfo->cinfo, COL_INFO)) + col_append_fstr(pinfo->cinfo, COL_INFO, ", Dest Count=%u", dest_count); offset += 1; @@ -751,11 +742,11 @@ dissect_aodv_draft_01_v6_rerr(tvbuff_t *tvb, packet_info *pinfo, aodv_unreach_dest_tree = proto_item_add_subtree(tj, ett_aodv_unreach_dest); for (i = 0; i < dest_count; i++) { proto_tree_add_item(aodv_unreach_dest_tree, hf_aodv_dest_seqno, - tvb, offset, 4, FALSE); + tvb, offset, 4, ENC_BIG_ENDIAN); offset += 4; proto_tree_add_item(aodv_unreach_dest_tree, hf_aodv_unreach_dest_ipv6, - tvb, offset, INET6_ADDRLEN, FALSE); + tvb, offset, INET6_ADDRLEN, ENC_BIG_ENDIAN); offset += INET6_ADDRLEN; } } @@ -785,7 +776,7 @@ dissect_aodv(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) return 0; } - if (check_col(pinfo->cinfo, COL_INFO)) + col_add_str(pinfo->cinfo, COL_INFO, val_to_str(type, type_vals, "Unknown AODV Packet Type (%u)")); diff --git a/epan/dissectors/packet-aoe.c b/epan/dissectors/packet-aoe.c index a71ef0e919..89636f8247 100644 --- a/epan/dissectors/packet-aoe.c +++ b/epan/dissectors/packet-aoe.c @@ -279,39 +279,35 @@ dissect_ata_pdu(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset, /* aflags */ aflags=tvb_get_guint8(tvb, offset); - proto_tree_add_item(tree, hf_aoe_aflags_e, tvb, offset, 1, FALSE); + proto_tree_add_item(tree, hf_aoe_aflags_e, tvb, offset, 1, ENC_BIG_ENDIAN); if(aflags&AOE_AFLAGS_E){ - proto_tree_add_item(tree, hf_aoe_aflags_d, tvb, offset, 1, FALSE); + proto_tree_add_item(tree, hf_aoe_aflags_d, tvb, offset, 1, ENC_BIG_ENDIAN); } if(aflags&AOE_AFLAGS_W){ - proto_tree_add_item(tree, hf_aoe_aflags_a, tvb, offset, 1, FALSE); + proto_tree_add_item(tree, hf_aoe_aflags_a, tvb, offset, 1, ENC_BIG_ENDIAN); } - proto_tree_add_item(tree, hf_aoe_aflags_w, tvb, offset, 1, FALSE); + proto_tree_add_item(tree, hf_aoe_aflags_w, tvb, offset, 1, ENC_BIG_ENDIAN); offset++; /* err/feature */ - proto_tree_add_item(tree, hf_aoe_err_feature, tvb, offset, 1, FALSE); + proto_tree_add_item(tree, hf_aoe_err_feature, tvb, offset, 1, ENC_BIG_ENDIAN); offset++; /* sector count */ - proto_tree_add_item(tree, hf_aoe_sector_count, tvb, offset, 1, FALSE); + proto_tree_add_item(tree, hf_aoe_sector_count, tvb, offset, 1, ENC_BIG_ENDIAN); offset++; /* ata command/status */ if(!response){ - proto_tree_add_item(tree, hf_aoe_acmd, tvb, offset, 1, FALSE); - if (check_col(pinfo->cinfo, COL_INFO)) { - col_append_fstr(pinfo->cinfo, COL_INFO, " ATA:%s", val_to_str(tvb_get_guint8(tvb, offset), ata_cmd_vals, " Unknown ATA<0x%02x>")); - } + proto_tree_add_item(tree, hf_aoe_acmd, tvb, offset, 1, ENC_BIG_ENDIAN); + col_append_fstr(pinfo->cinfo, COL_INFO, " ATA:%s", val_to_str(tvb_get_guint8(tvb, offset), ata_cmd_vals, " Unknown ATA<0x%02x>")); } else { - proto_tree_add_item(tree, hf_aoe_astatus, tvb, offset, 1, FALSE); + proto_tree_add_item(tree, hf_aoe_astatus, tvb, offset, 1, ENC_BIG_ENDIAN); if(ata_info != NULL && ata_info->request_frame){ /* we dont know what command it was unless we saw the request_frame */ tmp_item=proto_tree_add_uint(tree, hf_aoe_acmd, tvb, 0, 0, ata_info->cmd); PROTO_ITEM_SET_GENERATED(tmp_item); - if (check_col(pinfo->cinfo, COL_INFO)) { - col_append_fstr(pinfo->cinfo, COL_INFO, " ATA:%s", val_to_str(ata_info->cmd, ata_cmd_vals, " Unknown ATA<0x%02x>")); - } + col_append_fstr(pinfo->cinfo, COL_INFO, " ATA:%s", val_to_str(ata_info->cmd, ata_cmd_vals, " Unknown ATA<0x%02x>")); } } offset++; @@ -338,8 +334,8 @@ dissect_aoe_v1(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) flags_item=proto_tree_add_text(tree, tvb, 0, 1, "Flags:"); flags_tree=proto_item_add_subtree(flags_item, ett_aoe_flags); } - proto_tree_add_item(flags_tree, hf_aoe_flags_response, tvb, 0, 1, FALSE); - proto_tree_add_item(flags_tree, hf_aoe_flags_error, tvb, 0, 1, FALSE); + proto_tree_add_item(flags_tree, hf_aoe_flags_response, tvb, 0, 1, ENC_BIG_ENDIAN); + proto_tree_add_item(flags_tree, hf_aoe_flags_error, tvb, 0, 1, ENC_BIG_ENDIAN); if(flags_item){ proto_item_append_text(flags_item,(flags&AOE_FLAGS_RESPONSE)?" Response":" Request"); if(flags&AOE_FLAGS_ERROR){ @@ -350,26 +346,23 @@ dissect_aoe_v1(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) /* error */ if(flags&AOE_FLAGS_ERROR){ - proto_tree_add_item(tree, hf_aoe_error, tvb, 1, 1, FALSE); - if (check_col(pinfo->cinfo, COL_INFO)) { - col_append_fstr(pinfo->cinfo, COL_INFO, "Error:%s ", val_to_str(tvb_get_guint8(tvb, 1), error_vals, "Unknown error<%d>")); - } + proto_tree_add_item(tree, hf_aoe_error, tvb, 1, 1, ENC_BIG_ENDIAN); + col_append_fstr(pinfo->cinfo, COL_INFO, "Error:%s ", val_to_str(tvb_get_guint8(tvb, 1), error_vals, "Unknown error<%d>")); } /* major/minor address */ - proto_tree_add_item(tree, hf_aoe_major, tvb, 2, 2, FALSE); - proto_tree_add_item(tree, hf_aoe_minor, tvb, 4, 1, FALSE); + proto_tree_add_item(tree, hf_aoe_major, tvb, 2, 2, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_aoe_minor, tvb, 4, 1, ENC_BIG_ENDIAN); /* command */ cmd=tvb_get_guint8(tvb, 5); - proto_tree_add_item(tree, hf_aoe_cmd, tvb, 5, 1, FALSE); - if (check_col(pinfo->cinfo, COL_INFO)) { - col_append_fstr(pinfo->cinfo, COL_INFO, "%s %s", val_to_str(cmd, cmd_vals, "Unknown command<%d>"), (flags&AOE_FLAGS_RESPONSE)?"Response":"Request"); - } + proto_tree_add_item(tree, hf_aoe_cmd, tvb, 5, 1, ENC_BIG_ENDIAN); + col_append_fstr(pinfo->cinfo, COL_INFO, "%s %s", val_to_str(cmd, cmd_vals, "Unknown command<%d>"), (flags&AOE_FLAGS_RESPONSE)?"Response":"Request"); + /* tag */ tag=tvb_get_letohl(tvb, 6); - proto_tree_add_item(tree, hf_aoe_tag, tvb, 6, 4, FALSE); + proto_tree_add_item(tree, hf_aoe_tag, tvb, 6, 4, ENC_BIG_ENDIAN); switch(cmd){ @@ -393,7 +386,7 @@ dissect_aoe(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree) col_clear(pinfo->cinfo, COL_INFO); if (parent_tree) { - item = proto_tree_add_item(parent_tree, proto_aoe, tvb, 0, -1, FALSE); + item = proto_tree_add_item(parent_tree, proto_aoe, tvb, 0, -1, ENC_BIG_ENDIAN); tree = proto_item_add_subtree(item, ett_aoe); } diff --git a/epan/dissectors/packet-app-pkix-cert.c b/epan/dissectors/packet-app-pkix-cert.c index ed3dcc47d5..66893ab3f3 100644 --- a/epan/dissectors/packet-app-pkix-cert.c +++ b/epan/dissectors/packet-app-pkix-cert.c @@ -58,11 +58,10 @@ dissect_cert(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree) asn1_ctx_t asn1_ctx; asn1_ctx_init(&asn1_ctx, ASN1_ENC_BER, TRUE, pinfo); - if (check_col(pinfo->cinfo, COL_INFO)) - col_append_sep_fstr(pinfo->cinfo, COL_INFO, " ", "(application/pkix-cert)"); + col_append_sep_fstr(pinfo->cinfo, COL_INFO, " ", "(application/pkix-cert)"); if (tree) { - ti = proto_tree_add_item(tree, proto_cert, tvb, 0, -1, FALSE); + ti = proto_tree_add_item(tree, proto_cert, tvb, 0, -1, ENC_BIG_ENDIAN); subtree = proto_item_add_subtree(ti, ett_cert); } diff --git a/epan/dissectors/packet-arcnet.c b/epan/dissectors/packet-arcnet.c index 2c57375180..8fec7dd763 100644 --- a/epan/dissectors/packet-arcnet.c +++ b/epan/dissectors/packet-arcnet.c @@ -151,7 +151,7 @@ dissect_arcnet_common (tvbuff_t * tvb, packet_info * pinfo, proto_tree * tree, SET_ADDRESS(&pinfo->dl_dst, AT_ARCNET, 1, tvb_get_ptr(tvb, 1, 1)); SET_ADDRESS(&pinfo->dst, AT_ARCNET, 1, tvb_get_ptr(tvb, 1, 1)); - ti = proto_tree_add_item (tree, proto_arcnet, tvb, 0, -1, FALSE); + ti = proto_tree_add_item (tree, proto_arcnet, tvb, 0, -1, ENC_BIG_ENDIAN); arcnet_tree = proto_item_add_subtree (ti, ett_arcnet); @@ -162,7 +162,7 @@ dissect_arcnet_common (tvbuff_t * tvb, packet_info * pinfo, proto_tree * tree, offset++; if (has_offset) { - proto_tree_add_item (arcnet_tree, hf_arcnet_offset, tvb, offset, 2, FALSE); + proto_tree_add_item (arcnet_tree, hf_arcnet_offset, tvb, offset, 2, ENC_BIG_ENDIAN); offset += 2; } @@ -219,7 +219,7 @@ dissect_arcnet_common (tvbuff_t * tvb, packet_info * pinfo, proto_tree * tree, offset += 2; /* Another copy of the packet type appears after the padding. */ - proto_tree_add_item (arcnet_tree, hf_arcnet_protID, tvb, offset, 1, FALSE); + proto_tree_add_item (arcnet_tree, hf_arcnet_protID, tvb, offset, 1, ENC_BIG_ENDIAN); offset++; /* And after that comes the real split flag. */ @@ -230,7 +230,7 @@ dissect_arcnet_common (tvbuff_t * tvb, packet_info * pinfo, proto_tree * tree, split_flag); offset++; - proto_tree_add_item (arcnet_tree, hf_arcnet_sequence, tvb, offset, 2, FALSE); + proto_tree_add_item (arcnet_tree, hf_arcnet_sequence, tvb, offset, 2, ENC_BIG_ENDIAN); offset += 2; break; @@ -244,10 +244,7 @@ dissect_arcnet_common (tvbuff_t * tvb, packet_info * pinfo, proto_tree * tree, if (!dissector_try_uint (arcnet_dissector_table, protID, next_tvb, pinfo, tree)) { - if (check_col (pinfo->cinfo, COL_PROTOCOL)) - { col_add_fstr (pinfo->cinfo, COL_PROTOCOL, "0x%04x", protID); - } call_dissector (data_handle, next_tvb, pinfo, tree); } @@ -271,7 +268,7 @@ dissect_arcnet (tvbuff_t * tvb, packet_info * pinfo, proto_tree * tree) static void dissect_arcnet_linux (tvbuff_t * tvb, packet_info * pinfo, proto_tree * tree) { - dissect_arcnet_common (tvb, pinfo, tree, TRUE, FALSE); + dissect_arcnet_common (tvb, pinfo, tree, TRUE, ENC_BIG_ENDIAN); } static const value_string arcnet_prot_id_vals[] = { diff --git a/epan/dissectors/packet-armagetronad.c b/epan/dissectors/packet-armagetronad.c index 7274e0907d..3dda5017ba 100644 --- a/epan/dissectors/packet-armagetronad.c +++ b/epan/dissectors/packet-armagetronad.c @@ -209,17 +209,17 @@ add_message(tvbuff_t * tvb, gint offset, proto_tree * tree, GString * info) /* DescriptorID field */ proto_tree_add_item(msg_tree, hf_armagetronad_descriptor_id, tvb, - offset, 2, FALSE); + offset, 2, ENC_BIG_ENDIAN); if (info) g_string_append_printf(info, "%s, ", descriptor); /* MessageID field */ proto_tree_add_item(msg_tree, hf_armagetronad_message_id, tvb, - offset + 2, 2, FALSE); + offset + 2, 2, ENC_BIG_ENDIAN); /* DataLen field */ proto_tree_add_item(msg_tree, hf_armagetronad_data_len, tvb, - offset + 4, 2, FALSE); + offset + 4, 2, ENC_BIG_ENDIAN); /* Data field */ add_message_data(tvb, offset + 6, data_len, msg_tree); @@ -240,14 +240,13 @@ dissect_armagetronad(tvbuff_t * tvb, packet_info * pinfo, proto_tree * tree) if (!is_armagetronad_packet(tvb)) return 0; - info = check_col(pinfo->cinfo, COL_INFO) ? g_string_new("") : NULL; + info = g_string_new(""); col_set_str(pinfo->cinfo, COL_PROTOCOL, "Armagetronad"); - if (info) - col_clear(pinfo->cinfo, COL_INFO); + col_clear(pinfo->cinfo, COL_INFO); - ti = proto_tree_add_item(tree, proto_armagetronad, tvb, 0, -1, FALSE); + ti = proto_tree_add_item(tree, proto_armagetronad, tvb, 0, -1, ENC_BIG_ENDIAN); armagetronad_tree = proto_item_add_subtree(ti, ett_armagetronad); /* For each message in the frame */ @@ -257,19 +256,17 @@ dissect_armagetronad(tvbuff_t * tvb, packet_info * pinfo, proto_tree * tree) /* After the messages, comes the SenderID */ sender = tvb_get_ntohs(tvb, offset); proto_tree_add_item(ti, hf_armagetronad_sender_id, tvb, offset, 2, - FALSE); - - if (info) { - gsize new_len = info->len - 2; /* Remove the trailing ", " */ - if (new_len > 0) - g_string_truncate(info, new_len); - else - g_string_assign(info, "No message"); - - col_add_fstr(pinfo->cinfo, COL_INFO, "[%s] from 0x%04x", - info->str, sender); - g_string_free(info, TRUE); - } + ENC_BIG_ENDIAN); + + gsize new_len = info->len - 2; /* Remove the trailing ", " */ + if (new_len > 0) + g_string_truncate(info, new_len); + else + g_string_assign(info, "No message"); + + col_add_fstr(pinfo->cinfo, COL_INFO, "[%s] from 0x%04x", + info->str, sender); + g_string_free(info, TRUE); return offset + 2; } diff --git a/epan/dissectors/packet-aruba-adp.c b/epan/dissectors/packet-aruba-adp.c index 109472e4c9..cb47401f6c 100644 --- a/epan/dissectors/packet-aruba-adp.c +++ b/epan/dissectors/packet-aruba-adp.c @@ -68,38 +68,36 @@ dissect_aruba_adp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) if (tree) { - ti = proto_tree_add_item(tree, proto_aruba_adp, tvb, 0, 0, FALSE); + ti = proto_tree_add_item(tree, proto_aruba_adp, tvb, 0, 0, ENC_BIG_ENDIAN); aruba_adp_tree = proto_item_add_subtree(ti, ett_aruba_adp); - proto_tree_add_item(aruba_adp_tree, hf_adp_version, tvb, 0, 2, FALSE); + proto_tree_add_item(aruba_adp_tree, hf_adp_version, tvb, 0, 2, ENC_BIG_ENDIAN); } type = tvb_get_ntohs(tvb, 2); if (tree) { - proto_tree_add_item(aruba_adp_tree, hf_adp_type, tvb, 2, 2, FALSE); + proto_tree_add_item(aruba_adp_tree, hf_adp_type, tvb, 2, 2, ENC_BIG_ENDIAN); - proto_tree_add_item(aruba_adp_tree, hf_adp_id, tvb, 4, 2, FALSE); + proto_tree_add_item(aruba_adp_tree, hf_adp_id, tvb, 4, 2, ENC_BIG_ENDIAN); } switch(type){ case ADP_REQUEST: - proto_tree_add_item(aruba_adp_tree, hf_adp_mac, tvb, 6, 6, FALSE); + proto_tree_add_item(aruba_adp_tree, hf_adp_mac, tvb, 6, 6, ENC_BIG_ENDIAN); mac_str = tvb_ether_to_str(tvb, 6); - if (check_col(pinfo->cinfo, COL_INFO)) - col_add_fstr(pinfo->cinfo, COL_INFO, "ADP Request Src MAC: %s", mac_str); + col_add_fstr(pinfo->cinfo, COL_INFO, "ADP Request Src MAC: %s", mac_str); proto_item_append_text(ti, ", Request Src MAC: %s", mac_str); break; case ADP_RESPONSE: - proto_tree_add_item(aruba_adp_tree, hf_adp_switchip, tvb, 6, 4, FALSE); + proto_tree_add_item(aruba_adp_tree, hf_adp_switchip, tvb, 6, 4, ENC_BIG_ENDIAN); switchip = tvb_ip_to_str(tvb, 6); - if (check_col(pinfo->cinfo, COL_INFO)) - col_add_fstr(pinfo->cinfo, COL_INFO, "ADP Response Switch IP: %s", switchip); + col_add_fstr(pinfo->cinfo, COL_INFO, "ADP Response Switch IP: %s", switchip); proto_item_append_text(ti, ", Response Switch IP: %s", switchip); break; diff --git a/epan/dissectors/packet-asap.c b/epan/dissectors/packet-asap.c index 5545112425..a375d9a9b8 100644 --- a/epan/dissectors/packet-asap.c +++ b/epan/dissectors/packet-asap.c @@ -805,8 +805,8 @@ dissect_asap_message(tvbuff_t *message_tvb, packet_info *pinfo, proto_tree *asap type = tvb_get_guint8(message_tvb, MESSAGE_TYPE_OFFSET); /* pinfo is NULL only if dissect_asap_message is called via dissect_error cause */ - if (pinfo && (check_col(pinfo->cinfo, COL_INFO))) - col_add_fstr(pinfo->cinfo, COL_INFO, "%s ", val_to_str(type, message_type_values, "Unknown ASAP type")); + if (pinfo) + col_add_fstr(pinfo->cinfo, COL_INFO, "%s ", val_to_str(type, message_type_values, "Unknown ASAP type")); if (asap_tree) { proto_tree_add_item(asap_tree, hf_message_type, message_tvb, MESSAGE_TYPE_OFFSET, MESSAGE_TYPE_LENGTH, ENC_BIG_ENDIAN); diff --git a/epan/dissectors/packet-asf.c b/epan/dissectors/packet-asf.c index 7f57ffc228..efe6902752 100644 --- a/epan/dissectors/packet-asf.c +++ b/epan/dissectors/packet-asf.c @@ -163,17 +163,16 @@ dissect_asf(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) type = tvb_get_guint8(tvb, 4); len = tvb_get_guint8(tvb, 7); - if (check_col(pinfo->cinfo, COL_INFO)) - col_add_str(pinfo->cinfo, COL_INFO, - val_to_str(type, asf_type_vals, "Unknown (0x%02x)")); + col_add_str(pinfo->cinfo, COL_INFO, + val_to_str(type, asf_type_vals, "Unknown (0x%02x)")); if (tree) { - ti = proto_tree_add_item(tree, proto_asf, tvb, 0, 8, FALSE); + ti = proto_tree_add_item(tree, proto_asf, tvb, 0, 8,ENC_BIG_ENDIAN); asf_tree = proto_item_add_subtree(ti, ett_asf); - proto_tree_add_item(asf_tree, hf_asf_iana, tvb, 0, 4, FALSE); - proto_tree_add_item(asf_tree, hf_asf_type, tvb, 4, 1, FALSE); - proto_tree_add_item(asf_tree, hf_asf_tag, tvb, 5, 1, FALSE); - proto_tree_add_item(asf_tree, hf_asf_len, tvb, 7, 1, FALSE); + proto_tree_add_item(asf_tree, hf_asf_iana, tvb, 0, 4,ENC_BIG_ENDIAN); + proto_tree_add_item(asf_tree, hf_asf_type, tvb, 4, 1,ENC_BIG_ENDIAN); + proto_tree_add_item(asf_tree, hf_asf_tag, tvb, 5, 1,ENC_BIG_ENDIAN); + proto_tree_add_item(asf_tree, hf_asf_len, tvb, 7, 1,ENC_BIG_ENDIAN); } if (len) { @@ -200,7 +199,7 @@ static void dissect_asf_open_session_request(tvbuff_t *tvb, proto_tree *tree, gint offset, gint len) { - proto_tree_add_item(tree, hf_asf_mgt_console_id, tvb, offset, 4, FALSE); + proto_tree_add_item(tree, hf_asf_mgt_console_id, tvb, offset, 4,ENC_BIG_ENDIAN); offset += 4; len -= 4; dissect_asf_payloads(tvb, tree, offset, len); @@ -210,9 +209,9 @@ static void dissect_asf_open_session_response(tvbuff_t *tvb, proto_tree *tree, gint offset, gint len) { - proto_tree_add_item(tree, hf_asf_rssp_status_code, tvb, offset, 1, FALSE); - proto_tree_add_item(tree, hf_asf_mgt_console_id, tvb, offset + 4, 4, FALSE); - proto_tree_add_item(tree, hf_asf_client_id, tvb, offset + 8, 4, FALSE); + proto_tree_add_item(tree, hf_asf_rssp_status_code, tvb, offset, 1,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_asf_mgt_console_id, tvb, offset + 4, 4,ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_asf_client_id, tvb, offset + 8, 4,ENC_BIG_ENDIAN); offset += 12; len -= 12; dissect_asf_payloads(tvb, tree, offset, len); @@ -236,8 +235,8 @@ dissect_asf_payloads(tvbuff_t *tvb, proto_tree *tree, plen, "%s: %u bytes", val_to_str(ptype, asf_payload_type_vals, "Unknown (%u)"), plen); ptree = proto_item_add_subtree(ti, ett_asf_payload); - proto_tree_add_item(ptree, hf_asf_payload_type, tvb, offset, 1, FALSE); - proto_tree_add_item(ptree, hf_asf_payload_len, tvb, offset + 2, 2, FALSE); + proto_tree_add_item(ptree, hf_asf_payload_type, tvb, offset, 1,ENC_BIG_ENDIAN); + proto_tree_add_item(ptree, hf_asf_payload_len, tvb, offset + 2, 2,ENC_BIG_ENDIAN); if ( ptype && (plen > 4) ) { switch ( ptype ) @@ -252,7 +251,7 @@ dissect_asf_payloads(tvbuff_t *tvb, proto_tree *tree, break; default: proto_tree_add_item(ptree, hf_asf_payload_data, tvb, - offset + 4, plen - 4, FALSE); + offset + 4, plen - 4,ENC_BIG_ENDIAN); break; } } @@ -274,8 +273,8 @@ dissect_asf_payload_authentication(tvbuff_t *tvb, proto_tree *tree, len, "Authentication Algorithm: %s", val_to_str(alg, asf_authentication_type_vals, "Unknown (%u)")); atree = proto_item_add_subtree(ti, ett_asf_alg_payload); - proto_tree_add_item(atree, hf_asf_auth_alg, tvb, offset, 1, FALSE); - proto_tree_add_item(atree, hf_asf_reserved, tvb, offset + 1, len - 1, FALSE); + proto_tree_add_item(atree, hf_asf_auth_alg, tvb, offset, 1,ENC_BIG_ENDIAN); + proto_tree_add_item(atree, hf_asf_reserved, tvb, offset + 1, len - 1,ENC_BIG_ENDIAN); } static void @@ -291,8 +290,8 @@ dissect_asf_payload_integrity(tvbuff_t *tvb, proto_tree *tree, len, "Integrity Algorithm: %s", val_to_str(alg, asf_integrity_type_vals, "Unknown (%u)")); atree = proto_item_add_subtree(ti, ett_asf_alg_payload); - proto_tree_add_item(atree, hf_asf_integrity_alg, tvb, offset, 1, FALSE); - proto_tree_add_item(atree, hf_asf_reserved, tvb, offset + 1, len - 1, FALSE); + proto_tree_add_item(atree, hf_asf_integrity_alg, tvb, offset, 1,ENC_BIG_ENDIAN); + proto_tree_add_item(atree, hf_asf_reserved, tvb, offset + 1, len - 1,ENC_BIG_ENDIAN); } void diff --git a/epan/dissectors/packet-auto_rp.c b/epan/dissectors/packet-auto_rp.c index c0eeaef744..4ba1bb3dd1 100644 --- a/epan/dissectors/packet-auto_rp.c +++ b/epan/dissectors/packet-auto_rp.c @@ -119,11 +119,10 @@ static void dissect_auto_rp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) ver_type = tvb_get_guint8(tvb, 0); rp_count = tvb_get_guint8(tvb, 1); - if (check_col(pinfo->cinfo, COL_INFO)) - col_add_fstr(pinfo->cinfo, COL_INFO, "%s (v%s) for %u RP%s", - val_to_str(lo_nibble(ver_type), auto_rp_type_vals, "Unknown"), - val_to_str(hi_nibble(ver_type), auto_rp_ver_vals, "Unknown"), - rp_count, plurality(rp_count, "", "s")); + col_add_fstr(pinfo->cinfo, COL_INFO, "%s (v%s) for %u RP%s", + val_to_str(lo_nibble(ver_type), auto_rp_type_vals, "Unknown"), + val_to_str(hi_nibble(ver_type), auto_rp_ver_vals, "Unknown"), + rp_count, plurality(rp_count, "", "s")); if (tree) { proto_item *ti, *tv; @@ -132,7 +131,7 @@ static void dissect_auto_rp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) guint16 holdtime; offset = 0; - ti = proto_tree_add_item(tree, proto_auto_rp, tvb, offset, -1, FALSE); + ti = proto_tree_add_item(tree, proto_auto_rp, tvb, offset, -1, ENC_BIG_ENDIAN); auto_rp_tree = proto_item_add_subtree(ti, ett_auto_rp); tv = proto_tree_add_text(auto_rp_tree, tvb, offset, 1, "Version: %s, Packet type: %s", |