diff options
Diffstat (limited to 'gorillanest.pl.fcgi')
| -rwxr-xr-x | gorillanest.pl.fcgi | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/gorillanest.pl.fcgi b/gorillanest.pl.fcgi index f4c0687..2692877 100755 --- a/gorillanest.pl.fcgi +++ b/gorillanest.pl.fcgi @@ -6,11 +6,14 @@ use warnings; use Syntax::Keyword::Try; use FCGI; -require "gorillanest.pl.cgi"; - -our $request = FCGI::Request(); +use lib '.'; +# BEGIN { require 'config.pl'; } +BEGIN { require 'gorillanest.pl.cgi'; } try { + open STDERR, '>', LOG_FILE or die LOG_FILE . ": $!"; + my $sock = FCGI::OpenSocket(SOCKET_FILE, 100); + my $request = FCGI::Request(\*STDIN, \*STDOUT, \*STDERR, \%ENV, $sock); while($request->Accept() >= 0) { master(); } |
