From: Howard Chu Date: Thu, 15 Apr 2004 10:25:14 +0000 (+0000) Subject: NUL-terminate alloc'd berbuf (ITS#3086) X-Git-Tag: OPENLDAP_REL_ENG_2_2_BP~9 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=affe8359846a8709ced099204dd0154abb8c0c5b;p=openldap NUL-terminate alloc'd berbuf (ITS#3086) --- diff --git a/libraries/liblber/io.c b/libraries/liblber/io.c index a4b7c1cc97..1159614d79 100644 --- a/libraries/liblber/io.c +++ b/libraries/liblber/io.c @@ -657,6 +657,7 @@ ber_get_next( AC_MEMCPY(ber->ber_buf + sblen, ber->ber_ptr, l); sblen += l; } + *ber->ber_end = '\0'; ber->ber_ptr = ber->ber_buf; ber->ber_usertag = 0; if ((ber_len_t)sblen == ber->ber_len) {