summaryrefslogtreecommitdiff
path: root/source3/rpc_parse
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2008-11-11 12:49:20 +0100
committerGünther Deschner <gd@samba.org>2008-11-19 23:25:33 +0100
commitf9d691d9d808ec2f91f3f469fe2201b0909a8552 (patch)
tree0dc1042629ae2a62c72fd40c402b612989a7008a /source3/rpc_parse
parent12fdb5eb4628db08a665791fb76d15e9f5894478 (diff)
downloadsamba-f9d691d9d808ec2f91f3f469fe2201b0909a8552.tar.gz
samba-f9d691d9d808ec2f91f3f469fe2201b0909a8552.tar.bz2
samba-f9d691d9d808ec2f91f3f469fe2201b0909a8552.zip
s3-ntsvcs: remove old hand-marshalling for ntsvcs getdevregprop.
Guenther
Diffstat (limited to 'source3/rpc_parse')
-rw-r--r--source3/rpc_parse/parse_misc.c54
-rw-r--r--source3/rpc_parse/parse_ntsvcs.c68
-rw-r--r--source3/rpc_parse/parse_prs.c33
3 files changed, 0 insertions, 155 deletions
diff --git a/source3/rpc_parse/parse_misc.c b/source3/rpc_parse/parse_misc.c
index cf989c8b5e..169e5cb560 100644
--- a/source3/rpc_parse/parse_misc.c
+++ b/source3/rpc_parse/parse_misc.c
@@ -558,60 +558,6 @@ bool smb_io_buffer5(const char *desc, BUFFER5 *buf5, prs_struct *ps, int depth)
}
/*******************************************************************
- Inits a REGVAL_BUFFER structure.
-********************************************************************/
-
-void init_regval_buffer(REGVAL_BUFFER *str, const uint8 *buf, size_t len)
-{
- ZERO_STRUCTP(str);
-
- /* max buffer size (allocated size) */
- str->buf_max_len = len;
- str->offset = 0;
- str->buf_len = buf != NULL ? len : 0;
-
- if (buf != NULL) {
- SMB_ASSERT(str->buf_max_len >= str->buf_len);
- str->buffer = (uint16 *)TALLOC_ZERO(talloc_tos(),
- str->buf_max_len);
- if (str->buffer == NULL)
- smb_panic("init_regval_buffer: talloc fail");
- memcpy(str->buffer, buf, str->buf_len);
- }
-}
-
-/*******************************************************************
- Reads or writes a REGVAL_BUFFER structure.
- the uni_max_len member tells you how large the buffer is.
- the uni_str_len member tells you how much of the buffer is really used.
-********************************************************************/
-
-bool smb_io_regval_buffer(const char *desc, prs_struct *ps, int depth, REGVAL_BUFFER *buf2)
-{
-
- prs_debug(ps, depth, desc, "smb_io_regval_buffer");
- depth++;
-
- if(!prs_align(ps))
- return False;
-
- if(!prs_uint32("buf_max_len", ps, depth, &buf2->buf_max_len))
- return False;
- if(!prs_uint32("offset ", ps, depth, &buf2->offset))
- return False;
- if(!prs_uint32("buf_len ", ps, depth, &buf2->buf_len))
- return False;
-
- /* buffer advanced by indicated length of string
- NOT by searching for null-termination */
-
- if(!prs_regval_buffer(True, "buffer ", ps, depth, buf2))
- return False;
-
- return True;
-}
-
-/*******************************************************************
creates a UNISTR2 structure: sets up the buffer, too
********************************************************************/
diff --git a/source3/rpc_parse/parse_ntsvcs.c b/source3/rpc_parse/parse_ntsvcs.c
index 2b15a45506..17b51fa751 100644
--- a/source3/rpc_parse/parse_ntsvcs.c
+++ b/source3/rpc_parse/parse_ntsvcs.c
@@ -77,71 +77,3 @@ bool ntsvcs_io_r_get_device_list(const char *desc, NTSVCS_R_GET_DEVICE_LIST *r_u
return True;
}
-
-/*******************************************************************
-********************************************************************/
-
-bool ntsvcs_io_q_get_device_reg_property(const char *desc, NTSVCS_Q_GET_DEVICE_REG_PROPERTY *q_u, prs_struct *ps, int depth)
-{
- if (q_u == NULL)
- return False;
-
- prs_debug(ps, depth, desc, "ntsvcs_io_q_get_device_reg_property");
- depth++;
-
- if(!prs_align(ps))
- return False;
-
- if ( !prs_io_unistr2("devicepath", ps, depth, &q_u->devicepath) )
- return False;
- if( !prs_align(ps) )
- return False;
-
- if ( !prs_uint32("property", ps, depth, &q_u->property) )
- return False;
- if ( !prs_uint32("unknown2", ps, depth, &q_u->unknown2) )
- return False;
- if ( !prs_uint32("buffer_size1", ps, depth, &q_u->buffer_size1) )
- return False;
- if ( !prs_uint32("buffer_size2", ps, depth, &q_u->buffer_size2) )
- return False;
- if ( !prs_uint32("unknown5", ps, depth, &q_u->unknown5) )
- return False;
-
- return True;
-
-}
-
-/*******************************************************************
-********************************************************************/
-
-bool ntsvcs_io_r_get_device_reg_property(const char *desc, NTSVCS_R_GET_DEVICE_REG_PROPERTY *r_u, prs_struct *ps, int depth)
-{
- if ( !r_u )
- return False;
-
- prs_debug(ps, depth, desc, "ntsvcs_io_r_get_device_reg_property");
- depth++;
-
- if ( !prs_align(ps) )
- return False;
-
- if ( !prs_uint32("unknown1", ps, depth, &r_u->unknown1) )
- return False;
-
- if ( !smb_io_regval_buffer("value", ps, depth, &r_u->value) )
- return False;
- if ( !prs_align(ps) )
- return False;
-
- if ( !prs_uint32("size", ps, depth, &r_u->size) )
- return False;
-
- if ( !prs_uint32("needed", ps, depth, &r_u->needed) )
- return False;
-
- if(!prs_werror("status", ps, depth, &r_u->status))
- return False;
-
- return True;
-}
diff --git a/source3/rpc_parse/parse_prs.c b/source3/rpc_parse/parse_prs.c
index a0d3ed7397..acc0cc88ef 100644
--- a/source3/rpc_parse/parse_prs.c
+++ b/source3/rpc_parse/parse_prs.c
@@ -1056,39 +1056,6 @@ bool prs_buffer5(bool charmode, const char *name, prs_struct *ps, int depth, BUF
}
/******************************************************************
- Stream a "not" unicode string, length/buffer specified separately,
- in byte chars. String is in little-endian format.
- ********************************************************************/
-
-bool prs_regval_buffer(bool charmode, const char *name, prs_struct *ps, int depth, REGVAL_BUFFER *buf)
-{
- char *p;
- char *q = prs_mem_get(ps, buf->buf_len);
- if (q == NULL)
- return False;
-
- if (UNMARSHALLING(ps)) {
- if (buf->buf_len > buf->buf_max_len) {
- return False;
- }
- if ( buf->buf_max_len ) {
- buf->buffer = PRS_ALLOC_MEM(ps, uint16, buf->buf_max_len);
- if ( buf->buffer == NULL )
- return False;
- } else {
- buf->buffer = NULL;
- }
- }
-
- p = (char *)buf->buffer;
-
- dbg_rw_punival(charmode, name, depth, ps, q, p, buf->buf_len/2);
- ps->data_offset += buf->buf_len;
-
- return True;
-}
-
-/******************************************************************
Stream a string, length/buffer specified separately,
in uint8 chars.
********************************************************************/