You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@apr.apache.org by Bill Stoddard <bi...@wstoddard.com> on 2003/08/07 15:28:25 UTC
Re: cvs commit: apr/locks/unix proc_mutex.c
wrowe@apache.org wrote:
> wrowe 2003/08/06 16:54:31
>
> Modified: locks/unix proc_mutex.c
> Log:
> Introduce the proc_mutex_no_tryacquire stub, returning APR_ENOTIMPL,
> for all unimplemented trylock vectors. Prevents us from simply
> segfaulting when a given proc_mutex style does not support trylock.
>
What's wrong with segfaulting? Better to segfault and know unambiguously
that the function is broken than forget to check a return code and think
the function is fine? My .02. You're call.
Bill
Re: cvs commit: apr/locks/unix proc_mutex.c
Posted by "William A. Rowe, Jr." <wr...@rowe-clan.net>.
At 08:28 AM 8/7/2003, Bill Stoddard wrote:
>wrowe@apache.org wrote:
>
>>wrowe 2003/08/06 16:54:31
>> Modified: locks/unix proc_mutex.c
>> Log:
>> Introduce the proc_mutex_no_tryacquire stub, returning APR_ENOTIMPL,
>> for all unimplemented trylock vectors. Prevents us from simply
>> segfaulting when a given proc_mutex style does not support trylock.
>>
>What's wrong with segfaulting? Better to segfault and know unambiguously that the function is broken than forget to check a return code and think the function is fine? My .02. You're call.
Agreed - either behavior could be valid.
However, it seems the rest of the suite (other lock methods, other platforms)
all return APR_ENOTIMPL. That suggests to me that we should be consistent.
So FirstBill is a mild -.1 against, and I'm a mild +.1 for this patch... other ideas
or comments?
Bill