From 1c7125629142bf00353bb6f15d7e996f06cb33d0 Mon Sep 17 00:00:00 2001 From: Matthew Chapman Date: Sun, 11 Apr 1999 01:39:16 +0000 Subject: Incorrect length (number of unicode characters rather than buffer size) passed to ascii_to_unibuf in make_buffer2 was breaking User Manager. (This used to be commit c518cef78d53a76451e5ea0ac93d75930306fa47) --- source3/rpc_parse/parse_misc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source3/rpc_parse') diff --git a/source3/rpc_parse/parse_misc.c b/source3/rpc_parse/parse_misc.c index 51587e6d7a..a84469f8f9 100644 --- a/source3/rpc_parse/parse_misc.c +++ b/source3/rpc_parse/parse_misc.c @@ -530,7 +530,7 @@ void make_buffer2(BUFFER2 *str, const char *buf, int len) str->undoc = 0; /* store the string */ - ascii_to_unibuf(str->buffer, buf, len); + ascii_to_unibuf(str->buffer, buf, MIN(str->buf_len, sizeof(str->buffer)-1)); } /******************************************************************* -- cgit