summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorBill Meier <wmeier@newsguy.com>2011-10-21 02:10:19 +0000
committerBill Meier <wmeier@newsguy.com>2011-10-21 02:10:19 +0000
commit794757ae8fbee85db2b24bc46b7e9cc492de01df (patch)
treea955184a13d8444bdec0de9200f261c46cfa2734 /plugins
parent449d732485da5a19b8a0d3ddef49ed30498712ff (diff)
downloadwireshark-794757ae8fbee85db2b24bc46b7e9cc492de01df.tar.gz
For proto_tree_add_item(..., proto_xxx, ...)use ENC_NA as the encoding arg.
Also: remove trailing whitespace for a number of files. svn path=/trunk/; revision=39503
Diffstat (limited to 'plugins')
-rw-r--r--plugins/ethercat/packet-ams.c18
-rw-r--r--plugins/ethercat/packet-ecatmb.c2
-rw-r--r--plugins/ethercat/packet-esl.c2
-rw-r--r--plugins/ethercat/packet-ethercat-datagram.c2
-rw-r--r--plugins/ethercat/packet-ethercat-frame.c8
-rw-r--r--plugins/ethercat/packet-ioraw.c18
-rw-r--r--plugins/ethercat/packet-nv.c24
-rw-r--r--plugins/gryphon/packet-gryphon.c2
-rw-r--r--plugins/irda/packet-ircomm.c8
-rw-r--r--plugins/irda/packet-irda.c14
-rw-r--r--plugins/m2m/packet-m2m.c2
-rw-r--r--plugins/opcua/opcua.c20
-rw-r--r--plugins/profinet/packet-pn-mrp.c34
-rw-r--r--plugins/profinet/packet-pn-rt.c80
-rw-r--r--plugins/tpg/packet-http.c2
-rw-r--r--plugins/unistim/packet-unistim.c2
-rw-r--r--plugins/wimaxasncp/packet-wimaxasncp.c2
17 files changed, 120 insertions, 120 deletions
diff --git a/plugins/ethercat/packet-ams.c b/plugins/ethercat/packet-ams.c
index e5d07ccb57..7a0f502618 100644
--- a/plugins/ethercat/packet-ams.c
+++ b/plugins/ethercat/packet-ams.c
@@ -8,17 +8,17 @@
* Wireshark - Network traffic analyzer
* By Gerald Combs <gerald@wireshark.org>
* Copyright 1998 Gerald Combs
- *
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
- *
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -380,10 +380,10 @@ static void dissect_ams(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
proto_item *ti, *anItem;
proto_tree *ams_tree = NULL, *ams_adstree, *ams_statetree;
gint offset = 0;
- guint ams_length = tvb_reported_length(tvb);
+ guint ams_length = tvb_reported_length(tvb);
guint16 stateflags = 0;
guint16 cmdId = 0;
-
+
char szText[200];
int nMax = sizeof(szText)-1;
@@ -405,9 +405,9 @@ static void dissect_ams(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
if (tree)
{
- ti = proto_tree_add_item(tree, proto_ams, tvb, 0, -1, TRUE);
+ ti = proto_tree_add_item(tree, proto_ams, tvb, 0, -1, ENC_NA);
ams_tree = proto_item_add_subtree(ti, ett_ams);
-
+
NetIdFormater(tvb, offset, szText, nMax);
proto_tree_add_string(ams_tree, hf_ams_targetnetid, tvb, offset, AmsNetId_Len, szText);
offset += AmsNetId_Len;
@@ -461,7 +461,7 @@ static void dissect_ams(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
{
/* Request */
switch ( cmdId )
- {
+ {
case ADSSRVID_READ:
{
col_append_str(pinfo->cinfo, COL_INFO, "ADS Read Request");
@@ -643,7 +643,7 @@ static void dissect_ams(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
{
/*guint32 cbLength;
guint32 nStamps;*/
-
+
anItem = proto_tree_add_item(ams_tree, hf_ams_adsdnrequest, tvb, offset, ams_length-offset, ENC_NA);
if( ams_length-offset >= TAdsDeviceNotificationReq_Len )
{
diff --git a/plugins/ethercat/packet-ecatmb.c b/plugins/ethercat/packet-ecatmb.c
index a9b0161744..700bdb935e 100644
--- a/plugins/ethercat/packet-ecatmb.c
+++ b/plugins/ethercat/packet-ecatmb.c
@@ -1305,7 +1305,7 @@ static void dissect_ecat_mailbox(tvbuff_t *tvb, packet_info *pinfo, proto_tree *
if( tree )
{
/* Create the mailbox sub tree */
- anItem = proto_tree_add_item(tree, proto_ecat_mailbox, tvb, 0, ETHERCAT_MBOX_HEADER_LEN+hdr.Length, TRUE);
+ anItem = proto_tree_add_item(tree, proto_ecat_mailbox, tvb, 0, ETHERCAT_MBOX_HEADER_LEN+hdr.Length, ENC_NA);
ecat_mailbox_tree = proto_item_add_subtree(anItem, ett_ecat_mailbox);
/* Create a mailbox header subtree */
diff --git a/plugins/ethercat/packet-esl.c b/plugins/ethercat/packet-esl.c
index f1de212f94..e35d073985 100644
--- a/plugins/ethercat/packet-esl.c
+++ b/plugins/ethercat/packet-esl.c
@@ -190,7 +190,7 @@ dissect_esl_header(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree) {
{
guint16 flags;
- ti = proto_tree_add_item(tree, proto_esl, tvb, 0, SIZEOF_ESLHEADER, TRUE);
+ ti = proto_tree_add_item(tree, proto_esl, tvb, 0, SIZEOF_ESLHEADER, ENC_NA);
esl_header_tree = proto_item_add_subtree(ti, ett_esl);
offset+=6;
diff --git a/plugins/ethercat/packet-ethercat-datagram.c b/plugins/ethercat/packet-ethercat-datagram.c
index 55b1726cae..c69b52735d 100644
--- a/plugins/ethercat/packet-ethercat-datagram.c
+++ b/plugins/ethercat/packet-ethercat-datagram.c
@@ -490,7 +490,7 @@ static void dissect_ecat_datagram(tvbuff_t *tvb, packet_info *pinfo, proto_tree
if( tree )
{
/* Create the EtherCAT datagram(s) subtree */
- ti = proto_tree_add_item(tree, proto_ecat_datagram, tvb, 0, -1, TRUE);
+ ti = proto_tree_add_item(tree, proto_ecat_datagram, tvb, 0, -1, ENC_NA);
ecat_datagrams_tree = proto_item_add_subtree(ti, ett_ecat);
proto_item_append_text(ti,": %s", szText);
diff --git a/plugins/ethercat/packet-ethercat-frame.c b/plugins/ethercat/packet-ethercat-frame.c
index 5db87a90ff..a5556e8fe6 100644
--- a/plugins/ethercat/packet-ethercat-frame.c
+++ b/plugins/ethercat/packet-ethercat-frame.c
@@ -8,17 +8,17 @@
* Wireshark - Network traffic analyzer
* By Gerald Combs <gerald@wireshark.org>
* Copyright 1998 Gerald Combs
- *
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
- *
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -80,7 +80,7 @@ static void dissect_ethercat_frame(tvbuff_t *tvb, packet_info *pinfo, proto_tree
if (tree)
{
- ti = proto_tree_add_item(tree, proto_ethercat_frame, tvb, offset, EtherCATFrameParserHDR_Len, TRUE);
+ ti = proto_tree_add_item(tree, proto_ethercat_frame, tvb, offset, EtherCATFrameParserHDR_Len, ENC_NA);
ethercat_frame_tree = proto_item_add_subtree(ti, ett_ethercat_frame);
proto_tree_add_item(ethercat_frame_tree, hf_ethercat_frame_length, tvb, offset, EtherCATFrameParserHDR_Len, ENC_LITTLE_ENDIAN);
diff --git a/plugins/ethercat/packet-ioraw.c b/plugins/ethercat/packet-ioraw.c
index e331039172..60ae836b95 100644
--- a/plugins/ethercat/packet-ioraw.c
+++ b/plugins/ethercat/packet-ioraw.c
@@ -8,17 +8,17 @@
* Wireshark - Network traffic analyzer
* By Gerald Combs <gerald@wireshark.org>
* Copyright 1998 Gerald Combs
- *
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
- *
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -60,18 +60,18 @@ static void dissect_ioraw(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
int nMax = sizeof(szText)-1;
guint ioraw_length = tvb_reported_length(tvb);
-
+
col_set_str(pinfo->cinfo, COL_PROTOCOL, "IO-RAW");
col_clear(pinfo->cinfo, COL_INFO);
-
+
IoRawSummaryFormater(szText, nMax);
col_append_str(pinfo->cinfo, COL_INFO, szText);
- if (tree)
- {
- ti = proto_tree_add_item(tree, proto_ioraw, tvb, 0, -1, TRUE);
+ if (tree)
+ {
+ ti = proto_tree_add_item(tree, proto_ioraw, tvb, 0, -1, ENC_NA);
ioraw_tree = proto_item_add_subtree(ti, ett_ioraw);
proto_item_append_text(ti,": %s",szText);
@@ -79,7 +79,7 @@ static void dissect_ioraw(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
offset+=IoRawParserHDR_Len;
proto_tree_add_item(ioraw_tree, hf_ioraw_data, tvb, offset, ioraw_length - offset, ENC_NA);
- }
+ }
}
void proto_register_ioraw(void)
diff --git a/plugins/ethercat/packet-nv.c b/plugins/ethercat/packet-nv.c
index 7490b7e7a8..21f0530290 100644
--- a/plugins/ethercat/packet-nv.c
+++ b/plugins/ethercat/packet-nv.c
@@ -8,17 +8,17 @@
* Wireshark - Network traffic analyzer
* By Gerald Combs <gerald@wireshark.org>
* Copyright 1998 Gerald Combs
- *
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
- *
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -82,11 +82,11 @@ static void NvPublisherFormater(tvbuff_t *tvb, gint offset, char *szText, int nM
tvb_get_guint8(tvb, nvOffset+2),
tvb_get_guint8(tvb, nvOffset+3),
tvb_get_guint8(tvb, nvOffset+4),
- tvb_get_guint8(tvb, nvOffset+5));
+ tvb_get_guint8(tvb, nvOffset+5));
}
static void NvVarHeaderFormater(tvbuff_t *tvb, gint offset, char *szText, int nMax)
-{
+{
g_snprintf ( szText, nMax, "Variable - Id = %d, Length = %d",
tvb_get_letohs(tvb, offset),
tvb_get_letohs(tvb, offset+4));
@@ -101,19 +101,19 @@ static void dissect_nv(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
int nMax = sizeof(szText)-1;
gint i;
-
+
col_set_str(pinfo->cinfo, COL_PROTOCOL, "TC-NV");
col_clear(pinfo->cinfo, COL_INFO);
-
+
NvSummaryFormater(tvb, offset, szText, nMax);
col_append_str(pinfo->cinfo, COL_INFO, szText);
- if (tree)
+ if (tree)
{
guint16 nv_count;
- ti = proto_tree_add_item(tree, proto_nv, tvb, 0, -1, TRUE);
+ ti = proto_tree_add_item(tree, proto_nv, tvb, 0, -1, ENC_NA);
nv_tree = proto_item_add_subtree(ti, ett_nv);
proto_item_append_text(ti,": %s",szText);
@@ -158,9 +158,9 @@ static void dissect_nv(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
offset+=sizeof(guint16);
proto_tree_add_item(nv_var_tree, hf_nv_data, tvb, offset, var_length, ENC_NA);
- offset+=var_length;
+ offset+=var_length;
}
- }
+ }
}
void proto_register_nv(void)
@@ -236,6 +236,6 @@ void proto_reg_handoff_nv(void)
{
dissector_handle_t nv_handle;
- nv_handle = create_dissector_handle(dissect_nv, proto_nv);
+ nv_handle = create_dissector_handle(dissect_nv, proto_nv);
dissector_add_uint("ecatf.type", 4, nv_handle);
}
diff --git a/plugins/gryphon/packet-gryphon.c b/plugins/gryphon/packet-gryphon.c
index 3d445552a6..8f6f9a7ce7 100644
--- a/plugins/gryphon/packet-gryphon.c
+++ b/plugins/gryphon/packet-gryphon.c
@@ -211,7 +211,7 @@ dissect_gryphon_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
}
if (!is_msgresp_add) {
- ti = proto_tree_add_item(tree, proto_gryphon, tvb, 0, -1, FALSE);
+ ti = proto_tree_add_item(tree, proto_gryphon, tvb, 0, -1, ENC_NA);
gryphon_tree = proto_item_add_subtree(ti, ett_gryphon);
} else
gryphon_tree = tree;
diff --git a/plugins/irda/packet-ircomm.c b/plugins/irda/packet-ircomm.c
index 8615e5be43..e5264867b5 100644
--- a/plugins/irda/packet-ircomm.c
+++ b/plugins/irda/packet-ircomm.c
@@ -12,12 +12,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
- *
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -190,7 +190,7 @@ static void dissect_cooked_ircomm(tvbuff_t* tvb, packet_info* pinfo, proto_tree*
if (root)
{
/* create display subtree for the protocol */
- proto_item* ti = proto_tree_add_item(root, proto_ircomm, tvb, 0, -1, FALSE);
+ proto_item* ti = proto_tree_add_item(root, proto_ircomm, tvb, 0, -1, ENC_NA);
proto_tree* tree = proto_item_add_subtree(ti, ett_ircomm);
proto_tree* ctrl_tree;
@@ -232,7 +232,7 @@ static void dissect_raw_ircomm(tvbuff_t* tvb, packet_info* pinfo, proto_tree* ro
if (root)
{
/* create display subtree for the protocol */
- proto_item* ti = proto_tree_add_item(root, proto_ircomm, tvb, 0, -1, FALSE);
+ proto_item* ti = proto_tree_add_item(root, proto_ircomm, tvb, 0, -1, ENC_NA);
proto_tree* tree = proto_item_add_subtree(ti, ett_ircomm);
call_dissector(data_handle, tvb, pinfo, tree);
diff --git a/plugins/irda/packet-irda.c b/plugins/irda/packet-irda.c
index 4cbb6bb2d7..894e06ae32 100644
--- a/plugins/irda/packet-irda.c
+++ b/plugins/irda/packet-irda.c
@@ -475,7 +475,7 @@ static unsigned dissect_ttp(tvbuff_t* tvb, packet_info* pinfo, proto_tree* root,
if (root)
{
/* create display subtree for the protocol */
- proto_item* ti = proto_tree_add_item(root, proto_ttp, tvb, 0, -1, FALSE);
+ proto_item* ti = proto_tree_add_item(root, proto_ttp, tvb, 0, -1, ENC_NA);
proto_tree* tree = proto_item_add_subtree(ti, ett_ttp);
if (data)
@@ -610,7 +610,7 @@ static void dissect_iap_request(tvbuff_t* tvb, packet_info* pinfo, proto_tree* r
if (root)
{
/* create display subtree for the protocol */
- proto_item* ti = proto_tree_add_item(root, proto_iap, tvb, 0, -1, FALSE);
+ proto_item* ti = proto_tree_add_item(root, proto_iap, tvb, 0, -1, ENC_NA);
proto_tree* tree = proto_item_add_subtree(ti, ett_iap);
proto_tree* ctl_tree;
@@ -757,7 +757,7 @@ static void dissect_iap_result(tvbuff_t* tvb, packet_info* pinfo, proto_tree* ro
if (root)
{
/* create display subtree for the protocol */
- proto_item* ti = proto_tree_add_item(root, proto_iap, tvb, 0, -1, FALSE);
+ proto_item* ti = proto_tree_add_item(root, proto_iap, tvb, 0, -1, ENC_NA);
proto_tree* tree = proto_item_add_subtree(ti, ett_iap);
proto_tree* ctl_tree;
@@ -1070,7 +1070,7 @@ static void dissect_irlmp(tvbuff_t* tvb, packet_info* pinfo, proto_tree* root)
if (root)
{
/* create display subtree for the protocol */
- proto_item* ti = proto_tree_add_item(root, proto_irlmp, tvb, 0, -1, FALSE);
+ proto_item* ti = proto_tree_add_item(root, proto_irlmp, tvb, 0, -1, ENC_NA);
proto_tree* tree = proto_item_add_subtree(ti, ett_irlmp);
proto_tree* dst_tree;
@@ -1536,7 +1536,7 @@ static void dissect_xid(tvbuff_t* tvb, packet_info* pinfo, proto_tree* root, pro
if (root)
{
- ti = proto_tree_add_item(root, proto_irlmp, tvb, offset, -1, FALSE);
+ ti = proto_tree_add_item(root, proto_irlmp, tvb, offset, -1, ENC_NA);
lmp_tree = proto_item_add_subtree(ti, ett_irlmp);
}
@@ -1666,7 +1666,7 @@ static void dissect_log(tvbuff_t* tvb, packet_info* pinfo, proto_tree* root)
if (root)
{
- proto_item* ti = proto_tree_add_item(root, proto_log, tvb, 0, -1, FALSE);
+ proto_item* ti = proto_tree_add_item(root, proto_log, tvb, 0, -1, ENC_NA);
proto_tree* tree = proto_item_add_subtree(ti, ett_log);
if (pinfo->pseudo_header->irda.pkttype == IRDA_MISSED_MSG)
@@ -1727,7 +1727,7 @@ static void dissect_irlap(tvbuff_t* tvb, packet_info* pinfo, proto_tree* root)
proto_item* addr_item;
/* create display subtree for the protocol */
- ti = proto_tree_add_item(root, proto_irlap, tvb, 0, -1, FALSE);
+ ti = proto_tree_add_item(root, proto_irlap, tvb, 0, -1, ENC_NA);
tree = proto_item_add_subtree(ti, ett_irlap);
/* create subtree for the address field */
diff --git a/plugins/m2m/packet-m2m.c b/plugins/m2m/packet-m2m.c
index 98feea3147..0ee1b98da5 100644
--- a/plugins/m2m/packet-m2m.c
+++ b/plugins/m2m/packet-m2m.c
@@ -190,7 +190,7 @@ static void dissect_m2m(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
{ /* we are being asked for details */
- m2m_item = proto_tree_add_item(tree, proto_m2m, tvb, 0, -1, FALSE);
+ m2m_item = proto_tree_add_item(tree, proto_m2m, tvb, 0, -1, ENC_NA);
m2m_tree = proto_item_add_subtree(m2m_item, ett_m2m);
/* get the tvb reported length */
length = tvb_reported_length(tvb);
diff --git a/plugins/opcua/opcua.c b/plugins/opcua/opcua.c
index 683ed5bfcb..d50dfeb4d4 100644
--- a/plugins/opcua/opcua.c
+++ b/plugins/opcua/opcua.c
@@ -3,15 +3,15 @@
**
** Copyright (C) 2006-2007 ascolab GmbH. All Rights Reserved.
** Web: http://www.ascolab.com
-**
+**
** This program is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License
** as published by the Free Software Foundation; either version 2
** of the License, or (at your option) any later version.
-**
+**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-**
+**
** Project: OpcUa Wireshark Plugin
**
** Description: OpcUa Protocol Decoder.
@@ -105,7 +105,7 @@ void proto_register_opcua(void)
"OpcUa", /* short name */
"opcua" /* abbrev */
);
-
+
registerTransportLayerTypes(proto_opcua);
registerSecurityLayerTypes(proto_opcua);
registerApplicationLayerTypes(proto_opcua);
@@ -115,7 +115,7 @@ void proto_register_opcua(void)
registerServiceTypes();
registerFieldTypes(proto_opcua);
- proto_register_subtree_array(ett, array_length(ett));
+ proto_register_subtree_array(ett, array_length(ett));
range_convert_str(&global_tcp_ports_opcua, ep_strdup_printf("%u", OPCUA_PORT), 65535);
@@ -204,7 +204,7 @@ static void dissect_opcua_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree
{
msgtype = MSG_INVALID;
}
-
+
/* Clear out stuff in the info column */
col_set_str(pinfo->cinfo, COL_INFO, g_szMessageTypes[msgtype]);
@@ -217,7 +217,7 @@ static void dissect_opcua_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree
proto_item *ti = NULL;
proto_tree *transport_tree = NULL;
- ti = proto_tree_add_item(tree, proto_opcua, tvb, 0, -1, FALSE);
+ ti = proto_tree_add_item(tree, proto_opcua, tvb, 0, -1, ENC_NA);
transport_tree = proto_item_add_subtree(ti, ett_opcua_transport);
/* call the transport message dissector */
@@ -261,9 +261,9 @@ void proto_reg_handoff_opcua(void)
{
opcua_handle = create_dissector_handle(dissect_opcua, proto_opcua);
opcua_initialized = TRUE;
- }
- else
- {
+ }
+ else
+ {
/* clean up ports and their lists */
if (tcp_ports_opcua != NULL)
{
diff --git a/plugins/profinet/packet-pn-mrp.c b/plugins/profinet/packet-pn-mrp.c
index 9c34ea4430..f820b06cfe 100644
--- a/plugins/profinet/packet-pn-mrp.c
+++ b/plugins/profinet/packet-pn-mrp.c
@@ -1,5 +1,5 @@
/* packet-pn-mrp.c
- * Routines for PN-MRP (PROFINET Media Redundancy Protocol)
+ * Routines for PN-MRP (PROFINET Media Redundancy Protocol)
* packet dissection.
*
* $Id$
@@ -7,17 +7,17 @@
* Wireshark - Network traffic analyzer
* By Gerald Combs <gerald@wireshark.org>
* Copyright 1998 Gerald Combs
- *
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
- *
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -111,7 +111,7 @@ static const value_string pn_mrp_prio_vals[] = {
static int
-dissect_PNMRP_Common(tvbuff_t *tvb, int offset,
+dissect_PNMRP_Common(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree, proto_item *item)
{
guint16 sequence_id;
@@ -133,7 +133,7 @@ dissect_PNMRP_Common(tvbuff_t *tvb, int offset,
static int
-dissect_PNMRP_LinkUp(tvbuff_t *tvb, int offset,
+dissect_PNMRP_LinkUp(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree, proto_item *item)
{
guint8 mac[6];
@@ -165,7 +165,7 @@ dissect_PNMRP_LinkUp(tvbuff_t *tvb, int offset,
static int
-dissect_PNMRP_LinkDown(tvbuff_t *tvb, int offset,
+dissect_PNMRP_LinkDown(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree, proto_item *item)
{
guint8 mac[6];
@@ -197,7 +197,7 @@ dissect_PNMRP_LinkDown(tvbuff_t *tvb, int offset,
static int
-dissect_PNMRP_Test(tvbuff_t *tvb, int offset,
+dissect_PNMRP_Test(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree, proto_item *item)
{
guint16 prio;
@@ -238,7 +238,7 @@ dissect_PNMRP_Test(tvbuff_t *tvb, int offset,
static int
-dissect_PNMRP_TopologyChange(tvbuff_t *tvb, int offset,
+dissect_PNMRP_TopologyChange(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree, proto_item *item)
{
guint16 prio;
@@ -267,7 +267,7 @@ dissect_PNMRP_TopologyChange(tvbuff_t *tvb, int offset,
static int
-dissect_PNMRP_Option(tvbuff_t *tvb, int offset,
+dissect_PNMRP_Option(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree, proto_item *item, guint8 length)
{
guint32 oui;
@@ -276,7 +276,7 @@ dissect_PNMRP_Option(tvbuff_t *tvb, int offset,
/* OUI (organizational unique id) */
offset = dissect_pn_oid(tvb, offset, pinfo,tree, hf_pn_mrp_oui, &oui);
length -= 3;
-
+
switch (oui)
{
case OUI_SIEMENS:
@@ -308,7 +308,7 @@ dissect_PNMRP_Option(tvbuff_t *tvb, int offset,
static int
-dissect_PNMRP_PDU(tvbuff_t *tvb, int offset,
+dissect_PNMRP_PDU(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree, proto_item *item)
{
guint16 version;
@@ -382,22 +382,22 @@ dissect_PNMRP(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
{
proto_item *ti = NULL;
proto_tree *mrp_tree = NULL;
-
+
guint32 offset = 0;
col_set_str(pinfo->cinfo, COL_PROTOCOL, "PN-MRP");
-
+
/* Clear the information column on summary display */
col_clear(pinfo->cinfo, COL_INFO);
- if (tree)
+ if (tree)
{
- ti = proto_tree_add_item(tree, proto_pn_mrp, tvb, offset, -1, FALSE);
+ ti = proto_tree_add_item(tree, proto_pn_mrp, tvb, offset, -1, ENC_NA);
mrp_tree = proto_item_add_subtree(ti, ett_pn_mrp);
}
dissect_PNMRP_PDU(tvb, offset, pinfo, mrp_tree, ti);
-}
+}
void
diff --git a/plugins/profinet/packet-pn-rt.c b/plugins/profinet/packet-pn-rt.c
index a6dba80636..891093a3e1 100644
--- a/plugins/profinet/packet-pn-rt.c
+++ b/plugins/profinet/packet-pn-rt.c
@@ -80,7 +80,7 @@ static int hf_pn_rt_frag_status_fragment_number = -1;
static int hf_pn_rt_frag_data = -1;
-/*
+/*
* Define the trees for pn-rt
* We need one tree for pn-rt itself and one for the pn-rt data status subtree
*/
@@ -90,8 +90,8 @@ static int ett_pn_rt_sf = -1;
static int ett_pn_rt_frag = -1;
static int ett_pn_rt_frag_status = -1;
-/*
- * Here are the global variables associated with
+/*
+ * Here are the global variables associated with
* the various user definable characteristics of the dissection
*/
/* Place summary in proto tree */
@@ -127,10 +127,10 @@ dissect_DataStatus(tvbuff_t *tvb, int offset, proto_tree *tree, guint8 u8DataSta
proto_item *sub_item;
proto_tree *sub_tree;
- sub_item = proto_tree_add_uint_format(tree, hf_pn_rt_data_status,
+ sub_item = proto_tree_add_uint_format(tree, hf_pn_rt_data_status,
tvb, offset, 1, u8DataStatus,
- "DataStatus: 0x%02x (Frame: %s and %s, Provider: %s and %s)",
- u8DataStatus,
+ "DataStatus: 0x%02x (Frame: %s and %s, Provider: %s and %s)",
+ u8DataStatus,
(u8DataStatus & 0x04) ? "Valid" : "Invalid",
(u8DataStatus & 0x01) ? "Primary" : "Backup",
(u8DataStatus & 0x20) ? "Ok" : "Problem",
@@ -287,7 +287,7 @@ dissect_FRAG_PDU_heur(tvbuff_t *tvb,
/* XXX - should this use u8FragDataLength? */
- proto_tree_add_none_format(sub_tree, hf_pn_rt_frag_data, tvb, offset, tvb_length(tvb) - offset,
+ proto_tree_add_none_format(sub_tree, hf_pn_rt_frag_data, tvb, offset, tvb_length(tvb) - offset,
"FragData: %d bytes", tvb_length(tvb) - offset);
/* note: the actual defragmentation implementation is still missing here */
@@ -347,12 +347,12 @@ dissect_pn_rt(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
/* Initialize variables */
pn_rt_tree = NULL;
ti = NULL;
-
+
/*
* Set the columns now, so that they'll be set correctly if we throw
* an exception. We can set them (or append things) later again ....
*/
-
+
col_set_str(pinfo->cinfo, COL_PROTOCOL, "PN-RT");
col_set_str(pinfo->cinfo, COL_INFO, "PROFINET Real-Time");
@@ -629,7 +629,7 @@ dissect_pn_rt(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
ti = proto_tree_add_protocol_format(tree, proto_pn_rt, tvb, 0, pdu_len,
"PROFINET %s, %s", pszProtSummary, szFieldSummary);
} else {
- ti = proto_tree_add_item(tree, proto_pn_rt, tvb, 0, pdu_len, ENC_BIG_ENDIAN);
+ ti = proto_tree_add_item(tree, proto_pn_rt, tvb, 0, pdu_len, ENC_NA);
}
pn_rt_tree = proto_item_add_subtree(ti, ett_pn_rt);
@@ -641,23 +641,23 @@ dissect_pn_rt(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
/* add cycle counter */
proto_tree_add_uint_format(pn_rt_tree, hf_pn_rt_cycle_counter, tvb,
pdu_len - 4, 2, u16CycleCounter, "CycleCounter: %u", u16CycleCounter);
-
+
/* add data status subtree */
dissect_DataStatus(tvb, pdu_len - 2, tree, u8DataStatus);
/* add transfer status */
if (u8TransferStatus) {
proto_tree_add_uint_format(pn_rt_tree, hf_pn_rt_transfer_status, tvb,
- pdu_len - 1, 1, u8TransferStatus,
+ pdu_len - 1, 1, u8TransferStatus,
"TransferStatus: 0x%02x (ignore this frame)", u8TransferStatus);
} else {
proto_tree_add_uint_format(pn_rt_tree, hf_pn_rt_transfer_status, tvb,
- pdu_len - 1, 1, u8TransferStatus,
+ pdu_len - 1, 1, u8TransferStatus,
"TransferStatus: 0x%02x (OK)", u8TransferStatus);
}
}
}
-
+
/* update column info now */
col_add_str(pinfo->cinfo, COL_INFO, szFieldSummary);
col_set_str(pinfo->cinfo, COL_PROTOCOL, pszProtShort);
@@ -678,59 +678,59 @@ dissect_pn_rt(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
/* Register all the bits needed by the filtering engine */
-void
+void
proto_register_pn_rt(void)
{
static hf_register_info hf[] = {
{ &hf_pn_rt_frame_id, {
"FrameID", "pn_rt.frame_id", FT_UINT16, BASE_DEC, NULL, 0x0, NULL, HFILL }},
- { &hf_pn_rt_cycle_counter, {
+ { &hf_pn_rt_cycle_counter, {
"CycleCounter", "pn_rt.cycle_counter", FT_UINT16, BASE_DEC, NULL, 0x0, NULL, HFILL }},
- { &hf_pn_rt_data_status, {
+ { &hf_pn_rt_data_status, {
"DataStatus", "pn_rt.ds", FT_UINT8, BASE_HEX, 0, 0x0, NULL, HFILL }},
- { &hf_pn_rt_data_status_ignore, {
+ { &hf_pn_rt_data_status_ignore, {
"Ignore (1:Ignore/0:Evaluate)", "pn_rt.ds_ignore", FT_UINT8, BASE_HEX, 0, 0x80, NULL, HFILL }},
- { &hf_pn_rt_data_status_subframe_sender_mode, {
+ { &hf_pn_rt_data_status_subframe_sender_mode, {
"SubFrameSenderMode", "pn_rt.ds_subframe_sender_mode", FT_UINT8, BASE_HEX, 0, 0x40, NULL, HFILL }},
- { &hf_pn_rt_data_status_ok, {
+ { &hf_pn_rt_data_status_ok, {
"StationProblemIndicator (1:Ok/0:Problem)", "pn_rt.ds_ok", FT_UINT8, BASE_HEX, 0, 0x20, NULL, HFILL }},
- { &hf_pn_rt_data_status_operate, {
+ { &hf_pn_rt_data_status_operate, {
"ProviderState (1:Run/0:Stop)", "pn_rt.ds_operate", FT_UINT8, BASE_HEX, 0, 0x10, NULL, HFILL }},
- { &hf_pn_rt_data_status_res3, {
+ { &hf_pn_rt_data_status_res3, {
"Reserved (should be zero)", "pn_rt.ds_res3", FT_UINT8, BASE_HEX, 0, 0x08, NULL, HFILL }},
- { &hf_pn_rt_data_status_valid, {
+ { &hf_pn_rt_data_status_valid, {
"DataValid (1:Valid/0:Invalid)", "pn_rt.ds_valid", FT_UINT8, BASE_HEX, 0, 0x04, NULL, HFILL }},
- { &hf_pn_rt_data_status_res1, {
+ { &hf_pn_rt_data_status_res1, {
"Reserved (should be zero)", "pn_rt.ds_res1", FT_UINT8, BASE_HEX, 0, 0x02, NULL, HFILL }},
- { &hf_pn_rt_data_status_primary, {
+ { &hf_pn_rt_data_status_primary, {
"State (1:Primary/0:Backup)", "pn_rt.ds_primary", FT_UINT8, BASE_HEX, 0, 0x01, NULL, HFILL }},
{ &hf_pn_rt_transfer_status,
{ "TransferStatus", "pn_rt.transfer_status", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL }},
- { &hf_pn_rt_sf, {
+ { &hf_pn_rt_sf, {
"SubFrame", "pn_rt.sf", FT_NONE, BASE_NONE, NULL, 0x0, NULL, HFILL }},
- { &hf_pn_rt_sf_crc16, {
+ { &hf_pn_rt_sf_crc16, {
"CRC16", "pn_rt.sf.crc16", FT_UINT16, BASE_DEC, NULL, 0x0, NULL, HFILL }},
- { &hf_pn_rt_sf_position, {
+ { &hf_pn_rt_sf_position, {
"Position", "pn_rt.sf.position", FT_UINT8, BASE_DEC, NULL, 0x7F, NULL, HFILL }},
- { &hf_pn_rt_sf_position_control, {
+ { &hf_pn_rt_sf_position_control, {
"Control", "pn_rt.sf.position_control", FT_UINT8, BASE_DEC, VALS(pn_rt_position_control), 0x80, NULL, HFILL }},
- { &hf_pn_rt_sf_data_length, {
+ { &hf_pn_rt_sf_data_length, {
"DataLength", "pn_rt.sf.data_length", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL }},
- { &hf_pn_rt_sf_cycle_counter, {
+ { &hf_pn_rt_sf_cycle_counter, {
"CycleCounter", "pn_rt.sf.cycle_counter", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL }},
- { &hf_pn_rt_frag, {
+ { &hf_pn_rt_frag, {
"PROFINET Real-Time Fragment", "pn_rt.frag", FT_NONE, BASE_NONE, NULL, 0x0, NULL, HFILL }},
- { &hf_pn_rt_frag_data_length, {
+ { &hf_pn_rt_frag_data_length, {
"FragDataLength", "pn_rt.frag_data_length", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL }},
- { &hf_pn_rt_frag_status, {
+ { &hf_pn_rt_frag_status, {
"FragStatus", "pn_rt.frag_status", FT_NONE, BASE_NONE, NULL, 0x0, NULL, HFILL }},
- { &hf_pn_rt_frag_status_more_follows, {
+ { &hf_pn_rt_frag_status_more_follows, {
"MoreFollows", "pn_rt.frag_status.more_follows", FT_UINT8, BASE_HEX, VALS(pn_rt_frag_status_more_follows), 0x80, NULL, HFILL }},
- { &hf_pn_rt_frag_status_error, {
+ { &hf_pn_rt_frag_status_error, {
"Error", "pn_rt.frag_status.error", FT_UINT8, BASE_HEX, VALS(pn_rt_frag_status_error), 0x40, NULL, HFILL }},
- { &hf_pn_rt_frag_status_fragment_number, {
+ { &hf_pn_rt_frag_status_fragment_number, {
"FragmentNumber (zero based)", "pn_rt.frag_status.fragment_number", FT_UINT8, BASE_DEC, NULL, 0x3F, NULL, HFILL }},
- { &hf_pn_rt_frag_data, {
+ { &hf_pn_rt_frag_data, {
"FragData", "pn_rt.frag_data", FT_NONE, BASE_NONE, NULL, 0x00, NULL, HFILL }},
};
static gint *ett[] = {
@@ -740,7 +740,7 @@ proto_register_pn_rt(void)
&ett_pn_rt_frag,
&ett_pn_rt_frag_status
};
- module_t *pn_rt_module;
+ module_t *pn_rt_module;
proto_pn_rt = proto_register_protocol("PROFINET Real-Time Protocol",
"PN-RT", "pn_rt");
@@ -776,6 +776,6 @@ proto_reg_handoff_pn_rt(void)
dissector_add_uint("udp.port", 0x8892, pn_rt_handle);
heur_dissector_add("pn_rt", dissect_CSF_SDU_heur, proto_pn_rt);
- heur_dissector_add("pn_rt", dissect_FRAG_PDU_heur, proto_pn_rt);
+ heur_dissector_add("pn_rt", dissect_FRAG_PDU_heur, proto_pn_rt);
}
diff --git a/plugins/tpg/packet-http.c b/plugins/tpg/packet-http.c
index a834b2c55c..f84bafe6a1 100644
--- a/plugins/tpg/packet-http.c
+++ b/plugins/tpg/packet-http.c
@@ -52,7 +52,7 @@ static void dissect_http(tvbuff_t* tvb, packet_info* pinfo _U_, proto_tree* tree
http_info_value_t* msgdata = ep_alloc0(sizeof(http_info_value_t));
tvbparse_elem_t* reqresp;
tpg_parser_data_t* tpg;
- proto_item* pi = proto_tree_add_item(tree,proto_http,tvb,0,-1,FALSE);
+ proto_item* pi = proto_tree_add_item(tree,proto_http,tvb,0,-1,ENC_NA);
proto_tree* pt = proto_item_add_subtree(pi,ett_http);
tpg = tpg_start(pt,tvb,0,-1,http_tpg_data.wanted_http_sp, msgdata);
diff --git a/plugins/unistim/packet-unistim.c b/plugins/unistim/packet-unistim.c
index 72381b9b9f..9840d137ce 100644
--- a/plugins/unistim/packet-unistim.c
+++ b/plugins/unistim/packet-unistim.c
@@ -218,7 +218,7 @@ dissect_unistim(tvbuff_t *tvb,packet_info *pinfo,proto_tree *tree){
col_set_str(pinfo->cinfo, COL_PROTOCOL, "UNISTIM");
/* Clear out stuff in the info column */
col_clear(pinfo->cinfo, COL_INFO);
- ti = proto_tree_add_item(tree,proto_unistim,tvb,offset,-1,FALSE);
+ ti = proto_tree_add_item(tree,proto_unistim,tvb,offset,-1,ENC_NA);
overall_unistim_tree = proto_item_add_subtree(ti,ett_unistim);
ti1=proto_tree_add_text(overall_unistim_tree,tvb,offset,5,"Reliable UDP");
rudpm_tree=proto_item_add_subtree(ti1,ett_unistim);
diff --git a/plugins/wimaxasncp/packet-wimaxasncp.c b/plugins/wimaxasncp/packet-wimaxasncp.c
index 174fd26340..d29c25f6fe 100644
--- a/plugins/wimaxasncp/packet-wimaxasncp.c
+++ b/plugins/wimaxasncp/packet-wimaxasncp.c
@@ -2226,7 +2226,7 @@ dissect_wimaxasncp(
{
packet_item = proto_tree_add_item(
tree, proto_wimaxasncp,
- tvb, 0, MIN(WIMAXASNCP_HEADER_LENGTH_END, tvb_length(tvb)), FALSE);
+ tvb, 0, MIN(WIMAXASNCP_HEADER_LENGTH_END, tvb_length(tvb)), ENC_NA);
wimaxasncp_tree = proto_item_add_subtree(
packet_item, ett_wimaxasncp);