Harmony
  1. Harmony
  2. HARMONY-1106

[classlib][io] java.io.SequenceInputStream(InputStream, null) throws unexpected NPE

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Cannot Reproduce
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      [classlib][io] java.io.SequenceInputStream(InputStream, null) throws unexpected NPE

      Test-------------------------------------------------------------------------------------------------------------
      import java.io.*;

      public class Test {
      public static void main(String[] args) {
      try

      { ByteArrayInputStream bais = new ByteArrayInputStream(new byte[256]); SequenceInputStream sis = new SequenceInputStream(bais, null); System.out.println("new SequenceInputStream()="+sis); }

      catch (Exception unexpectedException)

      { unexpectedException.printStackTrace(); }

      }

      }

      Output----------------------------------------------------------------------------------------------------------

      JRockit
      java version "1.5.0"
      Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0-b64)
      BEA WebLogic JRockit(R) (build dra-38972-20041208-2001-win-ia32, R25.0.0-75, GC:
      System optimized over throughput (initial strategy singleparpar))

      new SequenceInputStream()=java.io.SequenceInputStream@1b3d48

      Harmony
      java version 1.5 (subset)

      (c) Copyright 1991, 2006 The Apache Software Foundation or its licensors, as app
      licable.
      java.lang.NullPointerException
      at java.io.SequenceInputStream.<init>(SequenceInputStream.java:57)
      at DateTest.main(DateTest.java:22)

      1. Harmony-1106.patch
        1 kB
        Igor V. Stolyarov

        Activity

        Hide
        Igor V. Stolyarov added a comment -

        Fix attached

        Show
        Igor V. Stolyarov added a comment - Fix attached
        Hide
        Tony Wu added a comment -

        It is no longer an issue in latest version (r448046)

        Show
        Tony Wu added a comment - It is no longer an issue in latest version (r448046)
        Hide
        Paulex Yang added a comment -

        Tony, thank you for looking at this.

        Igor, please verify if this issue doesn't exist now, thank you.

        Show
        Paulex Yang added a comment - Tony, thank you for looking at this. Igor, please verify if this issue doesn't exist now, thank you.

          People

          • Assignee:
            Unassigned
            Reporter:
            Igor V. Stolyarov
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development