summaryrefslogtreecommitdiff
path: root/source3/rpc_parse/parse_rpc.c
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>1998-04-10 18:21:16 +0000
committerJeremy Allison <jra@samba.org>1998-04-10 18:21:16 +0000
commite300c0346ff92035ff9568b55b34469193e29769 (patch)
treef4d6a8527410556a158c548f091011885016d9dc /source3/rpc_parse/parse_rpc.c
parent31ae9c7013be791717f6e77794ce8c8fc1c1c16c (diff)
downloadsamba-e300c0346ff92035ff9568b55b34469193e29769.tar.gz
samba-e300c0346ff92035ff9568b55b34469193e29769.tar.bz2
samba-e300c0346ff92035ff9568b55b34469193e29769.zip
includes.h: Moved HPUX undefine of SEMMSL to where it actually does something.
ipc.c: Added Luke's debug statement. locking_slow.c: Added FTRUNCATE_NEEDS_ROOT code for broken systems that need it (not sure what these are yet). membuffer.c ntdomain.h proto.h lib/rpc/include/rpc_dce.h lib/rpc/include/rpc_srvsvc.h lib/rpc/parse/parse_prs.c lib/rpc/parse/parse_rpc.c lib/rpc/server/srv_pipe_hnd.c lib/rpc/server/srv_util.c: Re-merge of Luke's NTDOM changes 'cos he's a lazy git with carpel tunnel syndrome :-). Jeremy. (This used to be commit 52e3966fbcf7b5fbdbc7cbe9ac0b453ab5bf3217)
Diffstat (limited to 'source3/rpc_parse/parse_rpc.c')
-rw-r--r--source3/rpc_parse/parse_rpc.c41
1 files changed, 33 insertions, 8 deletions
diff --git a/source3/rpc_parse/parse_rpc.c b/source3/rpc_parse/parse_rpc.c
index b025d3f1c8..8a5b6c172e 100644
--- a/source3/rpc_parse/parse_rpc.c
+++ b/source3/rpc_parse/parse_rpc.c
@@ -384,33 +384,58 @@ void smb_io_rpc_hdr_ba(char *desc, RPC_HDR_BA *rpc, prs_struct *ps, int depth)
}
/*******************************************************************
-creates an RPC_HDR_RR structure.
+creates an RPC_HDR_REQ structure.
********************************************************************/
-void make_rpc_hdr_rr(RPC_HDR_RR *hdr, uint32 data_len, uint8 opnum)
+void make_rpc_hdr_req(RPC_HDR_REQ *hdr, uint32 data_len, uint16 opnum)
{
if (hdr == NULL) return;
hdr->alloc_hint = data_len - 0x18; /* allocation hint */
hdr->context_id = 0; /* presentation context identifier */
- hdr->cancel_count = 0; /* cancel count */
hdr->opnum = opnum; /* opnum */
+}
+
+/*******************************************************************
+reads or writes an RPC_HDR_REQ structure.
+********************************************************************/
+void smb_io_rpc_hdr_req(char *desc, RPC_HDR_REQ *rpc, prs_struct *ps, int depth)
+{
+ if (rpc == NULL) return;
+
+ prs_debug(ps, depth, desc, "smb_io_rpc_hdr_req");
+ depth++;
+
+ prs_uint32("alloc_hint", ps, depth, &(rpc->alloc_hint));
+ prs_uint16("context_id", ps, depth, &(rpc->context_id));
+ prs_uint16("opnum ", ps, depth, &(rpc->opnum));
+}
+
+/*******************************************************************
+creates an RPC_HDR_RESP structure.
+********************************************************************/
+void make_rpc_hdr_resp(RPC_HDR_RESP *hdr, uint32 data_len)
+{
+ if (hdr == NULL) return;
+
+ hdr->alloc_hint = data_len - 0x18; /* allocation hint */
+ hdr->context_id = 0; /* presentation context identifier */
+ hdr->cancel_count = 0; /* cancel count */
hdr->reserved = 0; /* 0 - reserved */
}
/*******************************************************************
-reads or writes an RPC_HDR_RR structure.
+reads or writes an RPC_HDR_RESP structure.
********************************************************************/
-void smb_io_rpc_hdr_rr(char *desc, RPC_HDR_RR *rpc, prs_struct *ps, int depth)
+void smb_io_rpc_hdr_resp(char *desc, RPC_HDR_RESP *rpc, prs_struct *ps, int depth)
{
if (rpc == NULL) return;
- prs_debug(ps, depth, desc, "smb_io_rpc_hdr_rr");
+ prs_debug(ps, depth, desc, "smb_io_rpc_hdr_resp");
depth++;
prs_uint32("alloc_hint", ps, depth, &(rpc->alloc_hint));
- prs_uint8 ("context_id", ps, depth, &(rpc->context_id));
+ prs_uint16("context_id", ps, depth, &(rpc->context_id));
prs_uint8 ("cancel_ct ", ps, depth, &(rpc->cancel_count));
- prs_uint8 ("opnum ", ps, depth, &(rpc->opnum));
prs_uint8 ("reserved ", ps, depth, &(rpc->reserved));
}