[Bug 122] New: Charset / gjdoc fail to run.

[email protected] Fri, 25 Mar 2005 00:08:02 -0500
Newsgroups gmane.comp.java.vm.sablevm.bugs
Message-ID <[email protected]>
http://sablevm.org/bugs/show_bug.cgi?id=122

           Summary: Charset / gjdoc fail to run.
           Product: SableVM
           Version: 1.11[.x]
          Platform: Other
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: default
        AssignedTo: [email protected]
        ReportedBy: [email protected]
         QAContact: [email protected]


This bug prevents gjdoc from running.

Note: It was not present in trunk+3725 (dated 2005-03-15) but I didn't
researched where it was introduced.  I suspect it is a bug in Classpath
upstream.  If not, maybe some missing file in SableVM installation.

Basically if a file named:
META-INF/services/java.nio.charset.spi.CharsetProvider
is not found in the current directory, it fails.


---- sample code -----
import java.nio.charset.*;

public class CharsetBug {

  public static void main(String[] args) {
    Charset.forName("ISO-8859-1");
  }

}
------------

ibou:~/work/svn_sablejit/sandbox> java CharsetBug
java.lang.RuntimeException: java.io.FileNotFoundException: No such file or directory
   at java.nio.charset.Charset.providers (Charset.java:233)
   at java.nio.charset.Charset.charsetForName (Charset.java:166)
   at java.nio.charset.Charset.forName (Charset.java:148)
   at CharsetBug.main (CharsetBug.java:7)
   at java.lang.VirtualMachine.invokeMain (VirtualMachine.java)
   at java.lang.VirtualMachine.main (VirtualMachine.java:108)
Caused by: java.io.FileNotFoundException: No such file or directory
   at gnu.java.nio.channels.FileChannelImpl.open (FileChannelImpl.java)
   at gnu.java.nio.channels.FileChannelImpl.FileChannelImpl
(FileChannelImpl.java:106)
   at java.io.FileInputStream.FileInputStream (FileInputStream.java:108)
   at gnu.java.net.protocol.file.Connection.connect (Connection.java:142)
   at gnu.java.net.protocol.file.Connection.getInputStream (Connection.java:202)
   at java.net.URL.openStream (URL.java:682)
   at java.nio.charset.Charset.providers (Charset.java:215)
   ...5 more
ibou:~/work/svn_sablejit/sandbox> mkdir -p META-INF/services
ibou:~/work/svn_sablejit/sandbox> touch
META-INF/services/java.nio.charset.spi.CharsetProvider
ibou:~/work/svn_sablejit/sandbox> java CharsetBug



------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
You are the QA contact for the bug, or are watching the QA contact.