Subject: Re: bad diagassert in UTF8 module
To: None <email@example.com>
From: Ignatios Souvatzis <firstname.lastname@example.org>
Date: 03/12/2005 00:04:27
On Fri, Mar 11, 2005 at 10:52:46PM +0100, Joerg Sonnenberger wrote:
> The attached patch removes that assertions, but I'm not 100% sure
> if that is the solution.
> @@ -370,8 +368,6 @@
> _citrus_UTF8_encoding_module_init(_UTF8EncodingInfo * __restrict ei,
> const void * __restrict var, size_t lenvar)
> - _DIAGASSERT(ei != NULL);
> memset((void *)ei, 0, sizeof(*ei));
I didn't analyze at the others, because the patches don't carry enough
context with them, but this change looks adventurous to me. What would
be the point of not testing for a NULL pointer before memsetting, thus
getting a SEGV instead of whatever assert() uses?