aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-dcerpc-samr.c
diff options
context:
space:
mode:
authorAnders Broman <anders.broman@ericsson.com>2009-10-04 09:53:05 +0000
committerAnders Broman <anders.broman@ericsson.com>2009-10-04 09:53:05 +0000
commit1888382b1b76140f9b2972a82f5dd06707bb59f2 (patch)
treec693940cec6648fba36f51e7c1239de22f37ccd5 /epan/dissectors/packet-dcerpc-samr.c
parentdd4e4fc6d68cddcda17abb447c4e673aa9bfa426 (diff)
Atemt to fix compilation of samr for Windows.
svn path=/trunk/; revision=30294
Diffstat (limited to 'epan/dissectors/packet-dcerpc-samr.c')
-rw-r--r--epan/dissectors/packet-dcerpc-samr.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/epan/dissectors/packet-dcerpc-samr.c b/epan/dissectors/packet-dcerpc-samr.c
index cdbbb0c1b4..62b7028db3 100644
--- a/epan/dissectors/packet-dcerpc-samr.c
+++ b/epan/dissectors/packet-dcerpc-samr.c
@@ -2162,6 +2162,7 @@ static int
cnf_dissect_sec_desc_buf_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep)
{
guint64 len;
+ guint32 len32;
dcerpc_info *di = NULL;
e_ctx_hnd *polhnd = NULL;
dcerpc_call_value *dcv = NULL;
@@ -2174,6 +2175,10 @@ cnf_dissect_sec_desc_buf_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_t
}
offset = dissect_ndr_uint3264 (tvb, offset, pinfo, tree, drep,
hf_samr_sec_desc_buf_len, &len);
+
+ DISSECTOR_ASSERT(len<=G_MAXUINT32);
+ len32 = (guint32)len;
+
dcv = (dcerpc_call_value *)di->call_data;
if(dcv){
polhnd = dcv->pol;
@@ -2199,8 +2204,8 @@ cnf_dissect_sec_desc_buf_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_t
ami=&samr_alias_access_mask_info;
break;
}
- dissect_nt_sec_desc(tvb, offset, pinfo, tree, drep, TRUE, len, ami);
- offset += len;
+ dissect_nt_sec_desc(tvb, offset, pinfo, tree, drep, TRUE, len32, ami);
+ offset += len32;
return offset;
}
static int