From dc015f05c604e5d6c8f006228355840307a36447 Mon Sep 17 00:00:00 2001 From: Kurt Zeilenga Date: Fri, 14 May 2004 01:58:12 +0000 Subject: [PATCH] Import fix for ITS#1181 from Mark Adamson @ CMU.edu --- CHANGES | 1 + libraries/libldap/cyrus.c | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGES b/CHANGES index 1978fdf42b..4ab9635b14 100644 --- a/CHANGES +++ b/CHANGES @@ -8,6 +8,7 @@ OpenLDAP 2.2.12 Engineering Fixed slapd first component bug (ITS#3118) Fixed slapd TOLOWER macro use bug (ITS#3115) Fixed slapd TLS context clash bug (ITS#3109) + Fixed libldap SASL buffering bug (ITS#1181) Build Environment Fixed liblber memory debug portability bug (ITS#3116) Fixed back-perl perl portability bug (ITS#2554,2946) diff --git a/libraries/libldap/cyrus.c b/libraries/libldap/cyrus.c index f80a4c33c5..cb4a25c94b 100644 --- a/libraries/libldap/cyrus.c +++ b/libraries/libldap/cyrus.c @@ -264,7 +264,8 @@ sb_sasl_read( Sockbuf_IO_Desc *sbiod, void *buf, ber_len_t len) /* Read the length of the packet */ while ( p->sec_buf_in.buf_ptr < 4 ) { - ret = LBER_SBIOD_READ_NEXT( sbiod, p->sec_buf_in.buf_base, + ret = LBER_SBIOD_READ_NEXT( sbiod, p->sec_buf_in.buf_base + + p->sec_buf_in.buf_ptr, 4 - p->sec_buf_in.buf_ptr ); #ifdef EINTR if ( ( ret < 0 ) && ( errno == EINTR ) ) -- 2.39.5