This is the mail archive of the java-prs@sources.redhat.com mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: gcj/350: Only one result with Helloworld program under cygwin and W98


The following reply was made to PR gcj/350; it has been noted by GNATS.

From: Jeff Sturm <jeff.sturm@commerceone.com>
To: cormier@u-picardie.fr
Cc: java-gnats@sourceware.cygnus.com
Subject: Re: gcj/350: Only one result with Helloworld program under cygwin and 
 W98
Date: Tue, 19 Sep 2000 17:21:55 -0400

 cormier@u-picardie.fr wrote:
 > $ cat Hello.java
 > public class Hello{
 >         public static void main(String[] args){
 >                 System.out.println("Hello \n");
 >         }
 > }
 
 System.out is currently broken for Win32.  There is a fairly old patch if you
 are interested in the details... though it might not help if you are building
 libgcj today:
 
 http://sources.redhat.com/ml/java-patches/2000-q2/msg00056.html
 
 > $ ./hello
 > // Nothing is printed !!!!!!!!!!!!!!!!!!!!
 
 That's what I expected.  You can work around it by assigning System.out
 explicitly before you use it:
 
 try {
   System.setOut(new PrintStream(new FileOutputStream("CONOUT$")));
 } catch (Throwable t) {}
 System.out.println("Hello!");
 
 --
 Jeff Sturm
 jeff.sturm@commerceone.com

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]