perl-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stas Bekman <s...@stason.org>
Subject Re: ACL filesystem incompatibility and potential race condition
Date Fri, 04 Mar 2005 00:46:03 GMT
Stas Bekman wrote:
> Damon Buckwalter wrote:
> [...]
> 
>> The patch works nicely, but every error code returns FORBIDDEN still. 
>> I have a tweaked version attached that I think works better.
> 
> 
> looks good, but the overloading should work. see below.
> 
>>> sure, let's give them best info we can. with the patch above you will 
>>> get
>>> the exact rc.
>>>
>>
>>
>> I had to dig into $@->{rc} to get the exact return code.  $@ ==
>> APR::EACCES seemed to always evaluate true, even though the error log
>> showed different error codes for file not found versus permission
>> denied:
> 
> 
> Hmm, for some reason overloading doesn't work. Take a look at
> APR/Error.pm, which defines '==' as:
> 
>   sub num { $_[0]->{rc} }

which is obviously bogus. It should be:

   sub num_cmp { $_[0]->{rc} == $_[1] }

   '==' => \&num_cmp;

going to write some tests for APR::Error, before finishing off this issue.

-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Mime
View raw message