diff options
author | Jeremy Allison <jra@samba.org> | 2006-02-21 03:08:42 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 11:10:16 -0500 |
commit | 115996503ced64c478ed1cc857bd5a1528644b46 (patch) | |
tree | d0874a47a658c1a3d99c895a24ef7d10d4b02d22 /source3/rpc_parse | |
parent | 4ea92f30985466489a3b3faf5a1c90667175aad6 (diff) | |
download | samba-115996503ced64c478ed1cc857bd5a1528644b46.tar.gz samba-115996503ced64c478ed1cc857bd5a1528644b46.tar.bz2 samba-115996503ced64c478ed1cc857bd5a1528644b46.zip |
r13585: Sorry Gunther, had to revert this. It's got a buffer
overrun. Spoke to Jerry about the correct fix. Will add
this after.
Jeremy.
(This used to be commit 33e13aabd3825c59d15dc897536e2ccf8c8f6d5e)
Diffstat (limited to 'source3/rpc_parse')
-rw-r--r-- | source3/rpc_parse/parse_prs.c | 43 |
1 files changed, 0 insertions, 43 deletions
diff --git a/source3/rpc_parse/parse_prs.c b/source3/rpc_parse/parse_prs.c index 857a24cf0e..c4f9f512ab 100644 --- a/source3/rpc_parse/parse_prs.c +++ b/source3/rpc_parse/parse_prs.c @@ -1333,49 +1333,6 @@ BOOL prs_string_alloc(const char *name, prs_struct *ps, int depth, const char ** } /******************************************************************* - Stream a null-terminated string of fixed len. - ********************************************************************/ - -BOOL prs_string_len(const char *name, prs_struct *ps, int depth, char *str, int len) -{ - char *q; - int i; - BOOL charmode = True; - - q = prs_mem_get(ps, len+1); - if (q == NULL) - return False; - - for(i = 0; i < len; i++) { - if (UNMARSHALLING(ps)) - str[i] = q[i]; - else - q[i] = str[i]; - } - - /* The terminating null. */ - str[i] = '\0'; - - if (MARSHALLING(ps)) { - q[i] = '\0'; - } - - ps->data_offset += len+1; - - DEBUG(5,("%s%04x %s: ", tab_depth(depth), ps->data_offset, name)); - if (charmode) { - print_asc(5, (unsigned char*)str, len); - } else { - for (i = 0; i < len; i++) - DEBUG(5,("%04x ", str[i])); - } - DEBUG(5,("\n")); - - return True; -} - - -/******************************************************************* prs_uint16 wrapper. Call this and it sets up a pointer to where the uint16 should be stored, or gets the size if reading. ********************************************************************/ |