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

Re: (ITS#6172) Crash with baseObject in back-sql



openssl@mkarcher.dialup.fu-berlin.de wrote:

> slapd gets terminated by libc with an "invalid free" error message when using
> the baseObject configuration option (whether with or without file) at the time
> of the first query.
> 
> This is caused by freeing an entry using "free" that has been allocated using
> "entry_dup". This does not match (any more?). Essentially what the code was
> trying to to is to duplicate the sql_baseObject to bsi_e. The fix I suggest adds
> a function "entry_dup_to" to slapd so that backends can do this operation
> cleanly without having to create a temporary dynamic object there is no obvious
> clean way to get rid of.

I'd rather have a function that returns the entry struct to the pool 
without calling entry_clean(), to avoid as much as possible code 
duplication.  In any case, good catch.

Thanks, p.