/* $OpenLDAP$ */
/* This work is part of OpenLDAP Software <http://www.openldap.org/>.
*
- * Copyright 1998-2008 The OpenLDAP Foundation.
+ * Copyright 1998-2012 The OpenLDAP Foundation.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
}
len = strlen( line );
- while ( bp + len - buf > bsize ) {
+ while ( bp + len + 1 - buf > bsize ) {
size_t offset = bp - buf;
bsize += BUFSIZ;
buf = (char *) ch_realloc( buf, bsize );
rs->sr_flags = REP_ENTRY_MODIFIABLE;
send_search_entry( op, rs );
entry_free( rs->sr_entry );
+ rs->sr_attrs = NULL;
}
bp = buf;