Re: FastCGI with JDK1.1.1 -- patches

Sonya Rikhtverchik (rikhtver@OpenMarket.com)
Tue, 12 Aug 1997 13:59:59 -0400

Message-Id: <199708121759.NAA03736@u4-138.openmarket.com>
To: fastcgi-developers@OpenMarket.com
Subject: Re: FastCGI with JDK1.1.1 -- patches 
Date: Tue, 12 Aug 1997 13:59:59 -0400
From: Sonya Rikhtverchik <rikhtver@OpenMarket.com>


Subject: Re: FastCGI with JDK1.1.1 -- patches 
In-Reply-To: Your message of "Tue, 12 Aug 1997 09:37:45 EDT."
             <199708121337.JAA03070@u4-138.openmarket.com> 
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Date: Tue, 12 Aug 1997 13:41:57 -0400
From: Steve Harris <harris@OpenMarket.com>

This is correct. That one simple change will do the trick, and everything else 
should be unaffected. There might be a way to have one codde version that 
works for 1.0 and 1.1. Read the Java version out of System.properties and 
conditionalize redirect vs. assignment based on the result.
> 
> Date: Tue, 12 Aug 1997 14:33:09 +1000 (EST)
> From: Martin Pool <mbp@pharos.com.au>
> To: Stanley Gambarin <gambarin@OpenMarket.com>
> cc: fastcgi-developers@OpenMarket.com
> Subject: FastCGI with JDK1.1.1 -- patches
> Message-Id: <Pine.LNX.3.95.970812142751.16132E-100000@buffalo.pharos.com.au>
> MIME-Version: 1.0
> Content-Type: TEXT/PLAIN; charset=US-ASCII
> 
> In a message from April I found in the mailing list archive
> (http://www.fastcgi.com/mail-archive/0685.html), you wrote:
> 
> > You are correct that these streams have been renamed as
> > final and thus the currently provided functionality will not work
> > under JDK 1.1.1.  
> 
> The following small changes make the library work under JDK1.1, but
> unfortunately they don't work under JDK1.0.  :-(  There are only a few
> places in Java where they broke things like this, but there are a few.  I
> don't think there is any way to do this in a manner compatible with both
> versions.
> 
> You might care to add this to your FAQ, perhaps.
> 
> - --- FCGIInterface.java  Tue Aug 12 14:24:56 1997
> +++ FCGIInterface.java.~1~      Thu Oct 31 00:45:39 1996
> @@ -128,11 +128,11 @@
>                 /*
>                 * redirect stdin, stdout and stderr to fcgi socket
>                 */
> - -               System.setIn(new BufferedInputStream(request.inStream,
> 8192));
> - -               System.setOut(new PrintStream
> - -                             (new BufferedOutputStream(request.outStream,
> 8192)));
> - -               System.setErr(new PrintStream
> - -                             (new BufferedOutputStream(request.errStream,
> 512)));
> +               System.in = new BufferedInputStream(request.inStream,
> 8192);
> +               System.out = new PrintStream(new BufferedOutputStream(
> +                                               request.outStream, 8192));
> +               System.err = new PrintStream(new BufferedOutputStream(
> +                                               request.errStream, 512));
>                 System.setProperties(request.params);
>                 }
>         return 0;
> 
> Martin Pool <m.pool@pharos.com.au>
> Pharos Business Solutions
> (I'm not on the list -- please CC me on replies)
> 
> 
> ------- End of Forwarded Message
> 
> 
> 



------- End of Forwarded Message