On Mon, Dec 25, 2000 at 06:22:04PM -0800, Doug MacEachern wrote:
> i probably shouldn't be 'working' on xmas, but have some time to kill
> before the airport and have had this in mind since you first posted (4
> months ago!).  with the patch below and this package:
> http://perl.apache.org/~dougm/Sys-Stat-0.01.tar.gz
> 
> a fixup handler can modify the reported size like so:
> 
> sub MyFixup::handler {
>     my $r = shift;
>     my $stat = Sys::Stat->stat($r->filename);
>     $stat->size(10_000); #whatever size
>     $r->finfo($stat); #changed size will be reflected in dirindex output
>     0;
> }

Wow! Thanks for making that available, it exactly does what I wanted. I
just patched my modperl with the patch and also installed Sys::Stat and
use the new module in my MacBinary fixup handler and it works beautifully.

-- 
Jens-Uwe Mager

HELIOS Software GmbH
Steinriede 3
30827 Garbsen
Germany

Phone:          +49 5131 709320
FAX:            +49 5131 709325
Internet:       [EMAIL PROTECTED]

Reply via email to