X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=servers%2Fslapd%2Foverlays%2Fsssvlv.c;h=543d00f2c180b2354878121e1c73fa572d46342a;hb=3792e9ec5999fa6fce5ea29ebdf3ab6de84ed55a;hp=7eca86a6dcc457eaec62583f16e135e28d9c43e9;hpb=8917b774f71562cdfaaddd7641889ab79ef95273;p=openldap diff --git a/servers/slapd/overlays/sssvlv.c b/servers/slapd/overlays/sssvlv.c index 7eca86a6dc..543d00f2c1 100644 --- a/servers/slapd/overlays/sssvlv.c +++ b/servers/slapd/overlays/sssvlv.c @@ -2,7 +2,7 @@ /* $OpenLDAP$ */ /* This work is part of OpenLDAP Software . * - * Copyright 2009-2011 The OpenLDAP Foundation. + * Copyright 2009-2012 The OpenLDAP Foundation. * Portions copyright 2009 Symas Corporation. * All rights reserved. * @@ -436,6 +436,8 @@ static void send_list( Entry *e; LDAPControl *ctrls[2]; + rs->sr_attrs = op->ors_attrs; + /* FIXME: it may be better to just flatten the tree into * an array before doing all of this... */ @@ -586,6 +588,8 @@ static void send_page( Operation *op, SlapReply *rs, sort_op *so ) Entry *e; int rc; + rs->sr_attrs = op->ors_attrs; + while ( cur_node && rs->sr_nentries < so->so_page_size ) { sort_node *sn = cur_node->avl_data; @@ -630,8 +634,6 @@ static void send_entry( if ( !so->so_tree ) return; - rs->sr_attrs = op->ors_attrs; - /* RFC 2891: If critical then send the entries iff they were * succesfully sorted. If non-critical send all entries * whether they were sorted or not.