]> git.sur5r.net Git - openldap/commitdiff
Just use a fixed size slab for now
authorHoward Chu <hyc@openldap.org>
Wed, 9 Apr 2003 17:05:46 +0000 (17:05 +0000)
committerHoward Chu <hyc@openldap.org>
Wed, 9 Apr 2003 17:05:46 +0000 (17:05 +0000)
servers/slapd/connection.c

index b0a6378fbf8c50dd25dede4ba07bce8f6bd09f3d..7975348b22032582f62618da30608d5e19cdfecf 100644 (file)
@@ -913,8 +913,9 @@ connection_operation( void *ctx, void *arg_v )
        /* For all operations besides Add, we can use thread-local
         * storage for most mallocs.
         */
+#define        SLAB_SIZE       1048576
        if ( tag == LDAP_REQ_SEARCH ) {
-               sl_mem_create( ber_len( op->o_ber ) * 16, ctx );
+               sl_mem_create( SLAB_SIZE, ctx );
                ber_set_option( op->o_ber, LBER_OPT_BER_MEMCTX, ctx );
                op->o_tmpmemctx = ctx;
                op->o_tmpalloc = sl_malloc;