git.samba.org
/
samba.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
43e01fb
)
Merge of rpcstr_pull() termination fixes from 3.0
author
Tim Potter
<tpot@samba.org>
Wed, 28 May 2003 00:59:35 +0000
(
00:59
+0000)
committer
Tim Potter
<tpot@samba.org>
Wed, 28 May 2003 00:59:35 +0000
(
00:59
+0000)
source/lib/util_unistr.c
patch
|
blob
|
history
diff --git
a/source/lib/util_unistr.c
b/source/lib/util_unistr.c
index 08bb03986f145eb62868fb9c544e129163dc28ff..5df0828295f95ff8e5eec4fa617c6a152a575d16 100644
(file)
--- a/
source/lib/util_unistr.c
+++ b/
source/lib/util_unistr.c
@@
-229,7
+229,10
@@
char *skip_unibuf(char *src, size_t len)
*/
int rpcstr_pull(char* dest, void *src, int dest_len, int src_len, int flags)
{
- if (!src) return 0;
+ if (!src) {
+ dest[0] = 0;
+ return 0;
+ }
if(dest_len==-1) dest_len=MAXUNI-3;
return pull_ucs2(NULL, dest, src, dest_len, src_len, flags|STR_UNICODE|STR_NOALIGN);
}