CGI-Fast

 view release on metacpan or  search on metacpan

lib/CGI/Fast.pm  view on Meta::CPAN


sub _create_fcgi_request {
    my ( $in_fh,$out_fh,$err_fh ) = @_;
    # If we have a socket set, explicitly open it
    if ($ENV{FCGI_SOCKET_PATH} or $socket) {
        my $path    = $ENV{FCGI_SOCKET_PATH}  || $socket;
        my $perm    = $ENV{FCGI_SOCKET_PERM}  || $socket_perm;
        my $backlog = $ENV{FCGI_LISTEN_QUEUE} || $queue || 100;
        my $socket  = FCGI::OpenSocket( $path, $backlog );
        if ($path !~ /^:/ && defined $perm) {
            chmod $perm, $path or croak( "Couldn't chmod($path): $!" );
        }
        return FCGI::Request(
            ( $in_fh  || \*STDIN ),
            ( $out_fh || \*STDOUT ),
            ( $err_fh || \*STDERR ),
            \%ENV,
            $socket,
            1
        );
    }



( run in 0.237 second using v1.01-cache-2.11-cpan-496ff517765 )