aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors
diff options
context:
space:
mode:
authorStig Bjørlykke <stig@bjorlykke.org>2018-05-24 11:19:34 +0200
committerStig Bjørlykke <stig@bjorlykke.org>2018-05-24 10:38:11 +0000
commit1bdc98936fc6c768dddd03a2ce37d4eeae410e3e (patch)
treeec4102a3bf0de38c3abf23918068f82a61347f70 /epan/dissectors
parentafd0eef4f63839b30711cba6d0ebe334ff2ef450 (diff)
coap: Revert "Store ctype values in transaction tracking"
This change was based on a incomplete/incorrect implementation of LwM2M and is not correct because the payload encoding is mandatory in the response. This reverts commit 46fcf452ac0204152b6a4fd574547fb478f9e63b. This reverts commit b1e0cb01b33d1e6798e5f3b2f649b2359874c622. Change-Id: I89ae1f84e2735ad049a0f7c9045175940bed25cb Reviewed-on: https://code.wireshark.org/review/27770 Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org> Tested-by: Petri Dish Buildbot Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
Diffstat (limited to 'epan/dissectors')
-rw-r--r--epan/dissectors/packet-coap.c10
-rw-r--r--epan/dissectors/packet-coap.h2
2 files changed, 1 insertions, 11 deletions
diff --git a/epan/dissectors/packet-coap.c b/epan/dissectors/packet-coap.c
index 2a5dac9dc8..606dfcb46c 100644
--- a/epan/dissectors/packet-coap.c
+++ b/epan/dissectors/packet-coap.c
@@ -575,7 +575,7 @@ dissect_coap_opt_ctype(tvbuff_t *tvb, proto_item *head_item, proto_tree *subtree
coinfo->ctype_value = coap_get_opt_uint(tvb, offset, opt_length);
}
- coinfo->ctype_str = val_to_str_const(coinfo->ctype_value, vals_ctype, "Unknown Type");
+ coinfo->ctype_str = val_to_str(coinfo->ctype_value, vals_ctype, "Unknown Type %u");
proto_tree_add_string(subtree, hf, tvb, offset, opt_length, coinfo->ctype_str);
@@ -1102,10 +1102,6 @@ dissect_coap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, void* d
coap_trans->req_frame = pinfo->num;
coap_trans->rsp_frame = 0;
coap_trans->req_time = pinfo->fd->abs_ts;
- if (coinfo->ctype_str) {
- coap_trans->req_ctype_str = coinfo->ctype_str;
- coap_trans->req_ctype_value = coinfo->ctype_value;
- }
if (coinfo->uri_str_strbuf) {
/* Store the URI into CoAP transaction info */
coap_trans->uri_str_strbuf = wmem_strbuf_new(wmem_file_scope(), wmem_strbuf_get_str(coinfo->uri_str_strbuf));
@@ -1130,10 +1126,6 @@ dissect_coap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, void* d
/* Log the first matching response frame */
coap_trans->rsp_frame = pinfo->num;
}
- if (coap_trans->req_ctype_str) {
- coinfo->ctype_str = coap_trans->req_ctype_str;
- coinfo->ctype_value = coap_trans->req_ctype_value;
- }
if (coap_trans->uri_str_strbuf) {
/* Copy the URI stored in matching transaction info into CoAP packet info */
coinfo->uri_str_strbuf = wmem_strbuf_new(wmem_packet_scope(), wmem_strbuf_get_str(coap_trans->uri_str_strbuf));
diff --git a/epan/dissectors/packet-coap.h b/epan/dissectors/packet-coap.h
index 5a6ee85714..415ec7ab92 100644
--- a/epan/dissectors/packet-coap.h
+++ b/epan/dissectors/packet-coap.h
@@ -47,8 +47,6 @@ typedef struct {
guint32 req_frame;
guint32 rsp_frame;
nstime_t req_time;
- const gchar *req_ctype_str;
- guint req_ctype_value;
wmem_strbuf_t *uri_str_strbuf;
oscore_info_t *oscore_info; /* OSCORE transaction to decrypt response */
} coap_transaction;