dev  

apr_hash_set allocation failure behavior

Ivan Novick
Wed, 17 Mar 2010 15:19:22 -0700

Hello,

I am doing some testing with APR version 1.2.12

When adding to a hash table using apr_hash_set ... If memory can not be
allocated what is the expected behavior?

I am seeing apr_hash_set calls expand_array.

expand_array core dumps if memory can not be allocated.

Is this expected?  Is there a way to get an error code for a failed insert
to a table rather than a coredump?

Cheers,
Ivan