From: skimo Date: Wed, 18 Oct 2000 20:39:15 +0000 (+0000) Subject: o small documentation fix X-Git-Tag: 0.67_01~326 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=e40fb02cc6fa5c558f05ed7a15d64fe6f52781ca;p=catagits%2Ffcgi2.git o small documentation fix o compilation issues with older perls fixed o library initialization when using sockets fixed --- diff --git a/perl/ChangeLog b/perl/ChangeLog index f6c1a83..31e493e 100644 --- a/perl/ChangeLog +++ b/perl/ChangeLog @@ -1,3 +1,7 @@ + o small documentation fix + o compilation issues with older perls fixed + o library initialization when using sockets fixed + Version 0.54 -- 8 October 2000 Sven Verdoolaege o library fixes ("Rob Saccoccio" ) diff --git a/perl/FCGI.PL b/perl/FCGI.PL index b148dcb..abf9a4b 100644 --- a/perl/FCGI.PL +++ b/perl/FCGI.PL @@ -12,7 +12,7 @@ unless ($] >= 5.005) { print OUT while ; close OUT; __END__ -/* $Id: FCGI.PL,v 1.15 2000/07/10 09:56:49 skimo Exp $ */ +/* $Id: FCGI.PL,v 1.16 2000/10/18 20:39:15 skimo Exp $ */ #include "EXTERN.h" #include "perl.h" @@ -188,7 +188,7 @@ HV *hv; static int FCGI_Accept(FCGP_Request* request) { - static int isCGI = -1; /* -1: not checked; 0: FCGI; 1: FCGI */ + static int isCGI = -1; /* -1: not checked; 0: FCGI; 1: CGI */ int req_isCGI = request->requestPtr->listen_sock == FCGI_LISTENSOCK_FILENO ? @@ -334,6 +334,8 @@ FCGI_Init() MUTEX_INIT(&accept_mutex); #endif + + FCGX_Init(); } typedef FCGX_Stream * FCGI__Stream; diff --git a/perl/FCGI.pm b/perl/FCGI.pm index 25e6410..324563f 100644 --- a/perl/FCGI.pm +++ b/perl/FCGI.pm @@ -1,4 +1,4 @@ -# $Id: FCGI.pm,v 1.11 2000/10/08 19:48:23 skimo Exp $ +# $Id: FCGI.pm,v 1.12 2000/10/18 20:39:15 skimo Exp $ package FCGI; @@ -13,7 +13,7 @@ require DynaLoader; ); -$VERSION = '0.54'; +$VERSION = '0.55'; bootstrap FCGI; @@ -111,7 +111,14 @@ sub READLINE { sub OPEN { $_[0]->CLOSE; - @_ == 2 ? open($_[0], $_[1]) : open($_[0], $_[1], $_[2]); + if (@_ == 2) { + return open($_[0], $_[1]); + } else { + my $rc; + eval("$rc = open($_[0], $_[1], $_[2])"); + die $@ if $@; + return $rc; + } } 1; @@ -129,7 +136,7 @@ FCGI - Fast CGI module my $count = 0; my $request = FCGI::Request(); - while($request->accept() >= 0) { + while($request->Accept() >= 0) { print("Content-type: text/html\r\n\r\n", ++$count); }