From 6c1a786d6cb97abf2a550af08f94ba5ac9c6c4db Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Fri, 3 May 2002 13:07:42 +0000 Subject: [PATCH] Fix previous commit, wrong if condition --- libraries/libldap/cyrus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/libldap/cyrus.c b/libraries/libldap/cyrus.c index a65771cada..edb79429cd 100644 --- a/libraries/libldap/cyrus.c +++ b/libraries/libldap/cyrus.c @@ -312,7 +312,7 @@ sb_sasl_write( Sockbuf_IO_Desc *sbiod, void *buf, ber_len_t len) ber_pvt_sb_buf_destroy( &p->buf_out ); #endif sasl_getprop( p->sasl_context, SASL_MAXOUTBUF, (const void **)&max ); - if ( len > *max ) + if ( len > *max - 100 ) len = *max - 100; /* For safety margin */ ret = sasl_encode( p->sasl_context, buf, len, (SASL_CONST char **)&p->buf_out.buf_base, -- 2.39.5