aboutsummaryrefslogtreecommitdiffstats
path: root/packet-dcerpc-nt.c
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2002-11-28 21:03:36 +0000
committerGuy Harris <guy@alum.mit.edu>2002-11-28 21:03:36 +0000
commit0e050b1107790bf4774e9059e6639f6706c5291b (patch)
tree68aa4f0b3ddf8c5b371242eaee8176a84b2e8445 /packet-dcerpc-nt.c
parentca642e12bacebdbc643ef95da07e7795534cefc6 (diff)
downloadwireshark-0e050b1107790bf4774e9059e6639f6706c5291b.tar.gz
wireshark-0e050b1107790bf4774e9059e6639f6706c5291b.tar.bz2
wireshark-0e050b1107790bf4774e9059e6639f6706c5291b.zip
Get rid of the "pdata" argument to "dissect_dcerpc_uint16s()" and
"dissect_ndr_uint16s()"; "dissect_ndr_uint16s()" is always passed a null pointer, "dissect_dcerpc_uint16s()" is only called by "dissect_ndr_uint16s()", and the pointer returned through "pdata" is *NOT* guaranteed to be aligned on a 16-bit boundary so we don't want to tempt people to blithely dereference that pointer. svn path=/trunk/; revision=6699
Diffstat (limited to 'packet-dcerpc-nt.c')
-rw-r--r--packet-dcerpc-nt.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/packet-dcerpc-nt.c b/packet-dcerpc-nt.c
index cacace17fa..2f995009fa 100644
--- a/packet-dcerpc-nt.c
+++ b/packet-dcerpc-nt.c
@@ -2,7 +2,7 @@
* Routines for DCERPC over SMB packet disassembly
* Copyright 2001, Tim Potter <tpot@samba.org>
*
- * $Id: packet-dcerpc-nt.c,v 1.47 2002/11/28 03:57:50 guy Exp $
+ * $Id: packet-dcerpc-nt.c,v 1.48 2002/11/28 21:03:36 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
@@ -1419,7 +1419,7 @@ dissect_ndr_uint8s(tvbuff_t *tvb, gint offset, packet_info *pinfo,
int
dissect_dcerpc_uint16s(tvbuff_t *tvb, gint offset, packet_info *pinfo _U_,
proto_tree *tree, char *drep, int hfindex,
- int length, const guint16 **pdata)
+ int length)
{
const guint16 *data;
@@ -1429,16 +1429,13 @@ dissect_dcerpc_uint16s(tvbuff_t *tvb, gint offset, packet_info *pinfo _U_,
proto_tree_add_item (tree, hfindex, tvb, offset, length * 2, (drep[0] & 0x10));
}
- if (pdata)
- *pdata = data;
-
return offset + length * 2;
}
int
dissect_ndr_uint16s(tvbuff_t *tvb, gint offset, packet_info *pinfo,
proto_tree *tree, char *drep,
- int hfindex, int length, const guint16 **pdata)
+ int hfindex, int length)
{
dcerpc_info *di;
@@ -1452,5 +1449,5 @@ dissect_ndr_uint16s(tvbuff_t *tvb, gint offset, packet_info *pinfo,
offset++;
return dissect_dcerpc_uint16s(tvb, offset, pinfo,
- tree, drep, hfindex, length, pdata);
+ tree, drep, hfindex, length);
}