Thomas Klausner wrote:
Hi!

On Sun, Mar 11, 2007 at 03:26:13PM +0100, Thomas Klausner wrote:
Now, using Catalyst (on mod_perl 2.x), I'm doing this to send the file:

    $c->res->body( $fh );

This was maybe a bit to short:

   my $fh = IO::File->new( $full_path, 'r' );
   if ( defined $fh ) {
       binmode $fh;
       $c->res->body( $fh );
   }
                                        }
                                        

How about sendfile()
http://perl.apache.org/docs/2.0/api/Apache2/RequestIO.html#C_sendfile_

_______________________________________________
List: [email protected]
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/[email protected]/
Dev site: http://dev.catalyst.perl.org/

Reply via email to