s1ap: fix indent (use 2 spaces) and modelines info

Change-Id: I450f252d22b21438e55285b2af950f6a1c9f6d10
Reviewed-on: https://code.wireshark.org/review/16693
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
This commit is contained in:
Alexis La Goutte 2016-07-26 12:08:20 +02:00 committed by Anders Broman
parent 4d5cf21798
commit 761d555e4f
5 changed files with 1149 additions and 1094 deletions

View File

@ -54,7 +54,7 @@
#define PFNAME "s1ap" #define PFNAME "s1ap"
/* Dissector will use SCTP PPID 18 or SCTP port. IANA assigned port = 36412 */ /* Dissector will use SCTP PPID 18 or SCTP port. IANA assigned port = 36412 */
#define SCTP_PORT_S1AP 36412 #define SCTP_PORT_S1AP 36412
void proto_register_s1ap(void); void proto_register_s1ap(void);
void proto_reg_handoff_s1ap(void); void proto_reg_handoff_s1ap(void);
@ -87,9 +87,9 @@ static int ett_s1ap_UERadioPagingInformation = -1;
#include "packet-s1ap-ett.c" #include "packet-s1ap-ett.c"
enum{ enum{
INITIATING_MESSAGE, INITIATING_MESSAGE,
SUCCESSFUL_OUTCOME, SUCCESSFUL_OUTCOME,
UNSUCCESSFUL_OUTCOME UNSUCCESSFUL_OUTCOME
}; };
@ -191,47 +191,47 @@ static int dissect_UnsuccessfulOutcomeValue(tvbuff_t *tvb, packet_info *pinfo, p
static int static int
dissect_s1ap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_) dissect_s1ap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
{ {
proto_item *s1ap_item = NULL; proto_item *s1ap_item = NULL;
proto_tree *s1ap_tree = NULL; proto_tree *s1ap_tree = NULL;
/* make entry in the Protocol column on summary display */ /* make entry in the Protocol column on summary display */
col_set_str(pinfo->cinfo, COL_PROTOCOL, "S1AP"); col_set_str(pinfo->cinfo, COL_PROTOCOL, "S1AP");
/* create the s1ap protocol tree */ /* create the s1ap protocol tree */
s1ap_item = proto_tree_add_item(tree, proto_s1ap, tvb, 0, -1, ENC_NA); s1ap_item = proto_tree_add_item(tree, proto_s1ap, tvb, 0, -1, ENC_NA);
s1ap_tree = proto_item_add_subtree(s1ap_item, ett_s1ap); s1ap_tree = proto_item_add_subtree(s1ap_item, ett_s1ap);
dissect_S1AP_PDU_PDU(tvb, pinfo, s1ap_tree, NULL); dissect_S1AP_PDU_PDU(tvb, pinfo, s1ap_tree, NULL);
return tvb_captured_length(tvb); return tvb_captured_length(tvb);
} }
/*--- proto_reg_handoff_s1ap ---------------------------------------*/ /*--- proto_reg_handoff_s1ap ---------------------------------------*/
void void
proto_reg_handoff_s1ap(void) proto_reg_handoff_s1ap(void)
{ {
static gboolean Initialized=FALSE; static gboolean Initialized=FALSE;
static guint SctpPort; static guint SctpPort;
gcsna_handle = find_dissector_add_dependency("gcsna", proto_s1ap); gcsna_handle = find_dissector_add_dependency("gcsna", proto_s1ap);
if (!Initialized) { if (!Initialized) {
nas_eps_handle = find_dissector_add_dependency("nas-eps", proto_s1ap); nas_eps_handle = find_dissector_add_dependency("nas-eps", proto_s1ap);
lppa_handle = find_dissector_add_dependency("lppa", proto_s1ap); lppa_handle = find_dissector_add_dependency("lppa", proto_s1ap);
bssgp_handle = find_dissector_add_dependency("bssgp", proto_s1ap); bssgp_handle = find_dissector_add_dependency("bssgp", proto_s1ap);
dissector_add_for_decode_as("sctp.port", s1ap_handle); dissector_add_for_decode_as("sctp.port", s1ap_handle);
dissector_add_uint("sctp.ppi", S1AP_PAYLOAD_PROTOCOL_ID, s1ap_handle); dissector_add_uint("sctp.ppi", S1AP_PAYLOAD_PROTOCOL_ID, s1ap_handle);
Initialized=TRUE; Initialized=TRUE;
#include "packet-s1ap-dis-tab.c" #include "packet-s1ap-dis-tab.c"
} else { } else {
if (SctpPort != 0) { if (SctpPort != 0) {
dissector_delete_uint("sctp.port", SctpPort, s1ap_handle); dissector_delete_uint("sctp.port", SctpPort, s1ap_handle);
} }
} }
SctpPort=gbl_s1apSctpPort; SctpPort=gbl_s1apSctpPort;
if (SctpPort != 0) { if (SctpPort != 0) {
dissector_add_uint("sctp.port", SctpPort, s1ap_handle); dissector_add_uint("sctp.port", SctpPort, s1ap_handle);
} }
} }
/*--- proto_register_s1ap -------------------------------------------*/ /*--- proto_register_s1ap -------------------------------------------*/
@ -254,16 +254,16 @@ void proto_register_s1ap(void) {
/* List of subtrees */ /* List of subtrees */
static gint *ett[] = { static gint *ett[] = {
&ett_s1ap, &ett_s1ap,
&ett_s1ap_TransportLayerAddress, &ett_s1ap_TransportLayerAddress,
&ett_s1ap_ToTargetTransparentContainer, &ett_s1ap_ToTargetTransparentContainer,
&ett_s1ap_ToSourceTransparentContainer, &ett_s1ap_ToSourceTransparentContainer,
&ett_s1ap_RRCContainer, &ett_s1ap_RRCContainer,
&ett_s1ap_UERadioCapability, &ett_s1ap_UERadioCapability,
&ett_s1ap_RIMInformation, &ett_s1ap_RIMInformation,
&ett_s1ap_Cdma2000PDU, &ett_s1ap_Cdma2000PDU,
&ett_s1ap_Cdma2000SectorID, &ett_s1ap_Cdma2000SectorID,
&ett_s1ap_UERadioPagingInformation, &ett_s1ap_UERadioPagingInformation,
#include "packet-s1ap-ettarr.c" #include "packet-s1ap-ettarr.c"
}; };
@ -299,7 +299,15 @@ void proto_register_s1ap(void) {
} }
/*
* Editor modelines
*
* Local Variables:
* c-basic-offset: 2
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* ex: set shiftwidth=2 tabstop=8 expandtab:
* :indentSize=2:tabSize=8:noTabs=true:
*/

View File

@ -24,13 +24,26 @@
#define PACKET_S1AP_H #define PACKET_S1AP_H
typedef struct _s1ap_ctx_t { typedef struct _s1ap_ctx_t {
guint32 message_type; guint32 message_type;
guint32 ProcedureCode; guint32 ProcedureCode;
guint32 ProtocolIE_ID; guint32 ProtocolIE_ID;
guint32 ProtocolExtensionID; guint32 ProtocolExtensionID;
} s1ap_ctx_t; } s1ap_ctx_t;
#include "packet-s1ap-exp.h" #include "packet-s1ap-exp.h"
#endif /* PACKET_S1AP_H */ #endif /* PACKET_S1AP_H */
/*
* Editor modelines
*
* Local Variables:
* c-basic-offset: 2
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* ex: set shiftwidth=2 tabstop=8 expandtab:
* :indentSize=2:tabSize=8:noTabs=true:
*/

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -32,10 +32,10 @@
#define PACKET_S1AP_H #define PACKET_S1AP_H
typedef struct _s1ap_ctx_t { typedef struct _s1ap_ctx_t {
guint32 message_type; guint32 message_type;
guint32 ProcedureCode; guint32 ProcedureCode;
guint32 ProtocolIE_ID; guint32 ProtocolIE_ID;
guint32 ProtocolExtensionID; guint32 ProtocolExtensionID;
} s1ap_ctx_t; } s1ap_ctx_t;
@ -64,3 +64,16 @@ int dissect_s1ap_SONtransferCause_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_,
#line 35 "./asn1/s1ap/packet-s1ap-template.h" #line 35 "./asn1/s1ap/packet-s1ap-template.h"
#endif /* PACKET_S1AP_H */ #endif /* PACKET_S1AP_H */
/*
* Editor modelines
*
* Local Variables:
* c-basic-offset: 2
* tab-width: 8
* indent-tabs-mode: nil
* End:
*
* ex: set shiftwidth=2 tabstop=8 expandtab:
* :indentSize=2:tabSize=8:noTabs=true:
*/