diff options
author | Volker Lendecke <vlendec@samba.org> | 2007-09-21 10:23:35 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:30:56 -0500 |
commit | 7cbcb5f8c5bfd9bac6527232e7f5d011f03ed9ac (patch) | |
tree | 5a30dcd8c57b15b77a18ba0c9af3296420ddfe7b | |
parent | c1284b8eb8585f05a49866d2f93d25f5665b5cf8 (diff) | |
download | samba-7cbcb5f8c5bfd9bac6527232e7f5d011f03ed9ac.tar.gz samba-7cbcb5f8c5bfd9bac6527232e7f5d011f03ed9ac.tar.bz2 samba-7cbcb5f8c5bfd9bac6527232e7f5d011f03ed9ac.zip |
r25274: Attempt to fix RPC-SAMBA3-GETUSERNAME
(This used to be commit f6f64cf0b51f2fb841bd1c0f800c66114c213577)
-rw-r--r-- | source3/lib/util_unistr.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/lib/util_unistr.c b/source3/lib/util_unistr.c index a4952d137e..64cfd52120 100644 --- a/source3/lib/util_unistr.c +++ b/source3/lib/util_unistr.c @@ -361,7 +361,7 @@ int rpcstr_push(void* dest, const char *src, size_t dest_len, int flags) void unistr2_to_ascii(char *dest, const UNISTR2 *str, size_t maxlen) { - if (str == NULL) { + if ((str == NULL) || (str->uni_str_len == 0)) { *dest='\0'; return; } @@ -374,7 +374,7 @@ void unistr2_to_ascii(char *dest, const UNISTR2 *str, size_t maxlen) void unistr3_to_ascii(char *dest, const UNISTR3 *str, size_t maxlen) { - if (str == NULL) { + if ((str == NULL) || (str->uni_str_len == 0)) { *dest='\0'; return; } |