[mingw - Java] charset support

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[mingw - Java] charset support

SourceForge.net

Read and respond to this message at:
https://sourceforge.net/forum/message.php?msg_id=3187856
By: mol1111

Hello, I've tried to compile this simple code:

import java.io.*;

class BMEdit {

   
   public static void main(String[] args) throws Exception {
      BufferedReader reader = null;
      try {
         reader = new BufferedReader(new InputStreamReader(new
FileInputStream("bm.src"), "UTF-8"));
      }
      catch (FileNotFoundException e) {
         System.out.println("Nemohu otevrit soubor!");
         System.exit(-1);
      }
      String line = reader.readLine();
      while (line != null) {
         System.out.println(line);
         line = reader.readLine();
      }
   }

}

it works OK with GCJ/Linux and SunJRE/Windows, but GCJ/Windows converts all
characters into question marks. I've tried MinGW gcj 3.4.2 and 3.4.4

______________________________________________________________________
You are receiving this email because you elected to monitor this forum.
To stop monitoring this forum, login to SourceForge.net and visit:
https://sourceforge.net/forum/unmonitor.php?forum_id=286533


-------------------------------------------------------
This SF.Net email is sponsored by: NEC IT Guy Games.  How far can you shotput
a projector? How fast can you ride your desk chair down the office luge track?
If you want to score the big prize, get to know the little guy.  
Play to win an NEC 61" plasma display: http://www.necitguy.com/?r=20
_______________________________________________
MinGW-users mailing list
[hidden email]

You may change your MinGW Account Options or unsubscribe at:
https://lists.sourceforge.net/lists/listinfo/mingw-users
Loading...