aboutsummaryrefslogtreecommitdiffstats
path: root/packet-dcerpc-nt.h
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2002-03-10 21:30:11 +0000
committerGuy Harris <guy@alum.mit.edu>2002-03-10 21:30:11 +0000
commitbf1c8de9976b1dcc2b21ae5b02daa4fe44aed31c (patch)
tree31165602f903cd23a05653dc958ac0c8ca2b2b1c /packet-dcerpc-nt.h
parent2223587585a91f358e6755b943bdd13015a230df (diff)
Use "dissect_ndr_nt_UNICODE_STRING_str()", not
"dissect_ndr_nt_UNICODE_STRING_string()", in "samr_dissect_connect2_server()"; that eliminates an unnecessary extra level of protocol tree. That removes the last call to "dissect_ndr_nt_UNICODE_STRING_string()"; eliminate that routine. In "dissect_ndr_nt_UNICODE_STRING()", initially create the subtree with the name of the field as a string, so that if an exception is thrown before the name is set, the subtree won't show up as blank when displayed or printed. Also pass in the name to "dissect_ndr_pointer()", so the same happens for subtrees below it. Append only the string data, not its name, to items up the tree, as the name was put in when the item was created. Also, when adding a colon before the string, put a space after the colon, as is done elsewhere in Ethereal. When appending additional strings, put the blank before the new string, not after it. In "dissect_ndr_nt_STRING()", put the subtree into the string with the name of the field, rather than just "String". Pass in that name to "dissect_ndr_pointer()", so subtrees below it get a name when they're initially created. Get rid of colons in the name string passed to "dissect_ndr_pointer()" in some calls. Supply a non-null name string in more calls to "dissect_ndr_pointer()", and fix some calls to pass in the name of the field being handed to "dissect_ndr_pointer()". There's no need to fetch the entire "header_field_info" structure for a protocol field in order to get the field's name - just use "proto_registrar_get_name()" to get the name. Use a length of -1, not 0, when creating a subtree whose length will be set when the dissection of the items under the subtree is complete; that way, if an exception is thrown while dissecting the items - which means the item goes past the end of the tvbuff - the item will refer to all data to the end of the tvbuff, rather than referring to nothing. Fix a typo in the name of the "hf_samr_unknown_string" field. svn path=/trunk/; revision=4912
Diffstat (limited to 'packet-dcerpc-nt.h')
-rw-r--r--packet-dcerpc-nt.h6
1 files changed, 1 insertions, 5 deletions
diff --git a/packet-dcerpc-nt.h b/packet-dcerpc-nt.h
index 02a0d02c89..ead82138e2 100644
--- a/packet-dcerpc-nt.h
+++ b/packet-dcerpc-nt.h
@@ -2,7 +2,7 @@
* Routines for DCERPC over SMB packet disassembly
* Copyright 2001, Tim Potter <tpot@samba.org>
*
- * $Id: packet-dcerpc-nt.h,v 1.6 2002/03/06 10:01:17 sahlberg Exp $
+ * $Id: packet-dcerpc-nt.h,v 1.7 2002/03/10 21:30:10 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
@@ -77,10 +77,6 @@ guint32 prs_pop_ptr(GList **ptr_list, char *name);
#define ALIGN_TO_4_BYTES {if(offset&0x03)offset=(offset&0xfffffffc)+4;}
int
-dissect_ndr_nt_UNICODE_STRING_string(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep);
-int
dissect_ndr_nt_UNICODE_STRING_str(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree,
char *drep);