aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-pres.c
diff options
context:
space:
mode:
authorAnders Broman <anders.broman@ericsson.com>2005-09-06 18:08:45 +0000
committerAnders Broman <anders.broman@ericsson.com>2005-09-06 18:08:45 +0000
commit4029a91b8baa109f854cfab6f3d9db9b8d05737c (patch)
treec02a674d9b98689cc3796f7084ca8a02e5d1d7c1 /epan/dissectors/packet-pres.c
parent75dc6f1a66f3c31ba0714babc2102aaf4a892bf0 (diff)
Ftam - Use some mofe FN_PAR:s
PRES Dissect PDU type based on SS-user data from SES(Info from asn1 file). svn path=/trunk/; revision=15703
Diffstat (limited to 'epan/dissectors/packet-pres.c')
-rw-r--r--epan/dissectors/packet-pres.c48
1 files changed, 42 insertions, 6 deletions
diff --git a/epan/dissectors/packet-pres.c b/epan/dissectors/packet-pres.c
index 996e44c0e7..f8a9cec938 100644
--- a/epan/dissectors/packet-pres.c
+++ b/epan/dissectors/packet-pres.c
@@ -76,6 +76,12 @@ typedef struct _pres_ctx_oid_t {
} pres_ctx_oid_t;
static GHashTable *pres_ctx_oid_table = NULL;
+static int hf_pres_CP_type = -1;
+static int hf_pres_CPA_PPDU = -1;
+static int hf_pres_Abort_type = -1;
+static int hf_pres_CPR_PPDU = -1;
+static int hf_pres_Typed_data_type = -1;
+
/*--- Included file: packet-pres-hf.c ---*/
@@ -1418,21 +1424,30 @@ dissect_ppdu(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree)
}
switch(session->spdu_type){
- case SES_REFUSE:
- break;
case SES_CONNECTION_REQUEST:
- offset = dissect_pres_CP_type(FALSE, tvb, offset, pinfo, pres_tree, -1);
+ offset = dissect_pres_CP_type(FALSE, tvb, offset, pinfo, pres_tree, hf_pres_CP_type);
break;
case SES_CONNECTION_ACCEPT:
- offset = dissect_pres_CPA_PPDU(FALSE, tvb, offset, pinfo, pres_tree, -1);
+ offset = dissect_pres_CPA_PPDU(FALSE, tvb, offset, pinfo, pres_tree, hf_pres_CPA_PPDU);
break;
case SES_ABORT:
- offset = dissect_pres_Abort_type(FALSE, tvb, offset, pinfo, pres_tree, -1);
+ case SES_ABORT_ACCEPT:
+ offset = dissect_pres_Abort_type(FALSE, tvb, offset, pinfo, pres_tree, hf_pres_Abort_type);
break;
case SES_DATA_TRANSFER:
- offset = dissect_pres_CPC_type(FALSE, tvb, offset, pinfo, pres_tree, -1);
+ offset = dissect_pres_CPC_type(FALSE, tvb, offset, pinfo, pres_tree, hf_pres_user_data);
+ break;
+ case SES_TYPED_DATA:
+ offset = dissect_pres_Typed_data_type(FALSE, tvb, offset, pinfo, pres_tree, hf_pres_Typed_data_type);
+ break;
+ case SES_RESYNCHRONIZE:
+ offset = dissect_pres_RS_PPDU(FALSE, tvb, offset, pinfo, pres_tree, -1);
+ break;
+ case SES_RESYNCHRONIZE_ACK:
+ offset = dissect_pres_RSA_PPDU(FALSE, tvb, offset, pinfo, pres_tree, -1);
break;
default:
+ offset = dissect_pres_CPC_type(FALSE, tvb, offset, pinfo, pres_tree, hf_pres_user_data);
break;
}
@@ -1478,6 +1493,27 @@ void proto_register_pres(void) {
/* List of fields */
static hf_register_info hf[] = {
+ { &hf_pres_CP_type,
+ { "CP-type", "pres.cptype",
+ FT_NONE, BASE_NONE, NULL, 0,
+ "", HFILL }},
+ { &hf_pres_CPA_PPDU,
+ { "CPA-PPDU", "pres.cpapdu",
+ FT_NONE, BASE_NONE, NULL, 0,
+ "", HFILL }},
+ { &hf_pres_Abort_type,
+ { "Abort type", "pres.aborttype",
+ FT_UINT32, BASE_DEC, VALS(pres_Abort_type_vals), 0,
+ "", HFILL }},
+ { &hf_pres_CPR_PPDU,
+ { "CPR-PPDU", "pres.cprtype",
+ FT_UINT32, BASE_DEC, VALS(pres_CPR_PPDU_vals), 0,
+ "", HFILL }},
+ { &hf_pres_Typed_data_type,
+ { "Typed data type", "pres.Typed_data_type",
+ FT_UINT32, BASE_DEC, VALS(pres_Typed_data_type_vals), 0,
+ "", HFILL }},
+
/*--- Included file: packet-pres-hfarr.c ---*/