From: Kurt Zeilenga Date: Sun, 12 Oct 2003 06:07:02 +0000 (+0000) Subject: Finish off berbuf fix X-Git-Tag: OPENLDAP_REL_ENG_2_1_MP~594 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=71f484bad8b8f814fa36522fb62ecc9bcb0f9585;p=openldap Finish off berbuf fix --- diff --git a/servers/slapd/back-bdb/search.c b/servers/slapd/back-bdb/search.c index 2d3f245c50..7e37aca405 100644 --- a/servers/slapd/back-bdb/search.c +++ b/servers/slapd/back-bdb/search.c @@ -1515,8 +1515,8 @@ send_pagerequest_response( int tentries ) { LDAPControl ctrl, *ctrls[2]; - char berbuf[LBER_ELEMENT_SIZEOF]; - BerElement *ber = (BerElement *)berbuf; + BerElementBuffer berbuf; + BerElement *ber = (BerElement *)&berbuf; struct berval cookie = { 0, NULL }; PagedResultsCookie respcookie; @@ -1579,8 +1579,8 @@ bdb_build_sync_state_ctrl( int res; const char *text = NULL; - char berbuf[LBER_ELEMENT_SIZEOF]; - BerElement *ber = (BerElement *)berbuf; + BerElementBuffer berbuf; + BerElement *ber = (BerElement *)&berbuf; struct berval entryuuid_bv = { 0, NULL }; @@ -1639,8 +1639,8 @@ bdb_build_sync_done_ctrl( struct berval *csn ) { int ret; - char berbuf[LBER_ELEMENT_SIZEOF]; - BerElement *ber = (BerElement *)berbuf; + BerElementBuffer berbuf; + BerElement *ber = (BerElement *)&berbuf; ber_init2( ber, NULL, LBER_USE_DER ); @@ -1682,8 +1682,8 @@ bdb_send_ldap_intermediate( int state, struct berval *cookie ) { - char berbuf[LBER_ELEMENT_SIZEOF]; - BerElement *ber = (BerElement *)berbuf; + BerElementBuffer berbuf; + BerElement *ber = (BerElement *)&berbuf; struct berval rspdata; int ret;