Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4428802

FileCacheImageInputStream does not throw IllegalArgumentException - if stream is

    XMLWordPrintable

    Details

    • Subcomponent:
    • Resolved In Build:
      beta
    • CPU:
      generic
    • OS:
      generic

      Description



      Name: mlR10151 Date: 03/22/2001



      The descriptions for the FileCacheImageInputStream(InputStream stream, File cacheDir)
      says:

      . . .
      Throws:
                  IllegalArgumentException - if stream is null.
      . . .

      But it does not throw IllegalArgumentException as expected:
      ===================== a.java =======================
      import javax.imageio.stream.FileCacheImageInputStream;

      public class a {
          public static void main (String argv[]) throws Exception {
              try {
                  FileCacheImageInputStream fciis = new FileCacheImageInputStream(null, null);
                  System.out.println("FAILED");
              } catch (IllegalArgumentException e) {
                  System.out.println("PASSED");
              } catch (Throwable e) {
                  System.out.println("FAILED");
              }
          }
      }
      ===================== log =======================
      java version "1.4.0-beta"
      Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-beta-b56)
      Java HotSpot(TM) Client VM (build 1.4-beta-B56, mixed mode)
      FAILED

      ======================================================================

        Attachments

          Activity

            People

            Assignee:
            dricesunw Daniel Rice (Inactive)
            Reporter:
            mlsunw Ml Ml (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: