From: Kurt Zeilenga Date: Tue, 15 Jun 1999 02:31:15 +0000 (+0000) Subject: assert read/write to not in use sockbufs. This may cause problems X-Git-Tag: OPENLDAP_REL_ENG_2_BP~314 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=e8a45b52b31621c9ca5e0dd5ad9ce6e2458321b4;p=openldap assert read/write to not in use sockbufs. This may cause problems with slapd... slapd should be fixed. --- diff --git a/libraries/liblber/sockbuf.c b/libraries/liblber/sockbuf.c index ef00b9f9af..78251b361a 100644 --- a/libraries/liblber/sockbuf.c +++ b/libraries/liblber/sockbuf.c @@ -373,12 +373,11 @@ ber_pvt_sb_read( Sockbuf *sb, void *buf_arg, long len ) assert( buf_arg != NULL ); assert( sb != NULL ); - assert( SOCKBUF_VALID( sb ) ); + assert( SOCKBUF_VALID( sb ) ); assert( status_is_ok(sb) ); -#if 0 - /* breaks slapd :-< */ + + /* slapd might have problems with this */ assert( ber_pvt_sb_in_use( sb ) ); -#endif #ifdef TEST_PARTIAL_READ if ((rand() & 3)==1) { /* 1 out of 4 */ @@ -566,10 +565,10 @@ long ber_pvt_sb_write( Sockbuf *sb, void *buf, long len_arg ) assert( sb != NULL ); assert( SOCKBUF_VALID( sb ) ); assert( status_is_ok(sb) ); -#if 0 - /* unfortunately breaks slapd */ + + /* slapd might have problems with this */ assert( ber_pvt_sb_in_use( sb ) ); -#endif + #ifdef TEST_PARTIAL_WRITE if ((rand() & 3)==1) { /* 1 out of 4 */ errno = EWOULDBLOCK;