apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joe Orton <jor...@redhat.com>
Subject Re: svn commit: r330141 - /apr/apr-util/trunk/dbd/apr_dbd.c
Date Wed, 02 Nov 2005 11:12:37 GMT
On Wed, Nov 02, 2005 at 11:07:21AM +0000, Nick Kew wrote:
> On Wednesday 02 November 2005 09:03, Joe Orton wrote:
> 
> > This code has undefined behaviour by the C standard (calling a function
> > via a function pointer of incompatible type), such casts should never be
> > used at all IMO.
> 
> So where is the incompatible pointer type?

(apr_status_t (*)(apr_thread_mutex_t *)) is not compatible with 
(apr_status_t (*)(void *)), likewise for the ->end_transaction callback.  
If it was compatible the cast wouldn't be needed.

joe

Mime
View raw message