[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: commit: ldap/servers/slapd result.c value.c

On Thu, 2006-04-06 at 19:09 +0000, kurt@OpenLDAP.org wrote:

> 	value.c ->
> Log Message:
> Code which doesn't hanlding allocation failure should use
> ch_ routines, not SLAP_ macros

I believe the change in value.c is incorrect; if you use ch_realloc()
you shouldn't check the return value, as ch_realloc() will cause an
assert failure; or you handle the failure.  In this latter case, the
pointer should not be lost and a temporary should be used.  This is the
best we can do right now in terms of gracefully handling a realloc()


Ing. Pierangelo Masarati
Responsabile Open Solution
OpenLDAP Core Team

SysNet s.n.c.
Via Dossi, 8 - 27100 Pavia - ITALIA
Office:   +39.02.23998309          
Mobile:   +39.333.4963172
Email:    pierangelo.masarati@sys-net.it