Ernst Bunders wrote:
2 Due to an apperant change in java (1.4.1) specifications it is no longer
possible to pass characters outside the ascii set to imagemagick.
Is this a 1.4.1 and/or windows only problem? On my setup it is still possible to write an � for example.
- Linux - Java 1.4.2_03 - ImageMagick 5.4.3 - MMBase 1.7.0-rc2
I've attached a bugreport which I sent to sun, but never got an answer on......This includes a test-case.
Gerard
--- Begin Message ---************************************************ Your report has been assigned an internal review ID of: 233572This review ID is NOT visible on the "Java Developer Connection" (JDC). We greatly appreciate your interest in improving the quality of Java(tm) Technology from Sun Microsystems. Please be aware that the large volume of reports we receive sometimes prevents us from responding individually to each message. We currently have a three week response time for responding to Bug Reports. If the information is determined to be a new bug, or a duplicate of a known bug, you will receive a followup email containing a seven digit bug number. You may search for this bug number on the "Java Developer Connection" (JDC) at this URL: http://developer.java.sun.com/developer/bugParade/index.html. If you just reported an issue that could have a major impact on your project and you require a response, please consider purchasing one of the support offerings at this URL: http://java.sun.com/support/index.html --------------------------------------------------------------- dateCreated: Fri Jan 09 05:27:13 MST 2004 type: bug cust_name: Gerard van Enk cust_email: [EMAIL PROTECTED] jdcid: gvanenk status: Waiting category: java subcategory: classes_lang company: Million Pieces release: 1.4.2 hardware: x86 OSversion: Linux priority: 4 synopsis: Runtime.getRuntime().exec doesn't understand special utf-8 characters description: FULL PRODUCT VERSION : java version "1.4.2_03" Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_03-b02) Java HotSpot(TM) Client VM (build 1.4.2_03-b02, mixed mode) ADDITIONAL OS VERSION INFORMATION : Linux hat 2.4.18-bf2.4 #1 Son Apr 14 09:53:28 CEST 2002 i686 GNU/Linux A DESCRIPTION OF THE PROBLEM : Using special utf-8 characters (ie �, �, etc) in a native application using Runtime.getRuntime().exec doesn't work. It is working using jdk-1.3. STEPS TO FOLLOW TO REPRODUCE THE PROBLEM : See testcase. EXPECTED VERSUS ACTUAL BEHAVIOR : EXPECTED - [EMAIL PROTECTED]:/tmp/test$ /usr/local/sun/jdk1.3.1_06/bin/java execInput command: echo Caf� twee�ntwintig Here is the standard output of the command: Caf� twee�ntwintig Here is the standard error of the command (if any): ACTUAL - [EMAIL PROTECTED]:/tmp/test$ java execInput command: echo Caf?? twee??ntwintig Here is the standard output of the command: Caf?? twee??ntwintig Here is the standard error of the command (if any): REPRODUCIBILITY : This bug can be reproduced always. ---------- BEGIN SOURCE ---------- import java.io.*; class execInput { public static void main(String Argv[]) { try { String ls_str; String s = null; String line = "Caf� twee�ntwintig"; String[] command = {"echo",line}; System.out.println("command: " + command[0] + " " + command[1]); Process p = Runtime.getRuntime().exec(command); BufferedReader stdInput = new BufferedReader(new InputStreamReader(p.getInputStream())); BufferedReader stdError = new BufferedReader(new InputStreamReader(p.getErrorStream())); // read the output from the command System.out.println("Here is the standard output of the command:\n"); while ((s = stdInput.readLine()) != null) { System.out.println(s); } // read any errors from the attempted command System.out.println("Here is the standard error of the command (if any):\n"); while ((s = stdError.readLine()) != null) { System.out.println(s); } } catch (IOException e1) { System.err.println(e1); } } } ---------- END SOURCE ---------- workaround: comments: (company - Million Pieces , email - [EMAIL PROTECTED])
--- End Message ---
