summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorJean-François Micouleau <jfm@samba.org>2001-07-09 18:21:03 +0000
committerJean-François Micouleau <jfm@samba.org>2001-07-09 18:21:03 +0000
commitdb77d64a2020ddcde5039dbd1572c7ba78abc8ec (patch)
treee3c4b48ba015631c7954322b5ccbcec8950612b2 /source3
parent5512332cdb87a0ae503f916a499bef90ca8d74dc (diff)
downloadsamba-db77d64a2020ddcde5039dbd1572c7ba78abc8ec.tar.gz
samba-db77d64a2020ddcde5039dbd1572c7ba78abc8ec.tar.bz2
samba-db77d64a2020ddcde5039dbd1572c7ba78abc8ec.zip
when converting ascii to unicode, if the ascii string is NULL, don't
convert it, rpcstr_push doesn't like it. (This used to be commit a8006e6f3eb1e06f4d48727de31e1229d6eef58a)
Diffstat (limited to 'source3')
-rw-r--r--source3/rpc_parse/parse_misc.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/source3/rpc_parse/parse_misc.c b/source3/rpc_parse/parse_misc.c
index 216a6e2eca..857f964e31 100644
--- a/source3/rpc_parse/parse_misc.c
+++ b/source3/rpc_parse/parse_misc.c
@@ -910,6 +910,13 @@ void init_unistr2(UNISTR2 *str, const char *buf, size_t len)
return;
}
+ /*
+ * don't move this test above ! The UNISTR2 must be initialized !!!
+ * jfm, 7/7/2001.
+ */
+ if (buf==NULL)
+ return;
+
rpcstr_push((char *)str->buffer, buf, len, STR_TERMINATE);
}