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

Subject:callAs() not throwing NPE when action is null

    XMLWordPrintable

Details

    Backports

      Description

        It's observed that the Subject:callAs() method does not throw NPE as per spec.

        The spec mentions that : "Throws:
        NullPointerException - if action is null"

         For the piece of code : Subject.callAs(new Subject(),null);

        expected : NullPointerException.
        Actual behavior is : "java.util.concurrent.CompletionException" thrown instead.

        Attachments

          Issue Links

            Activity

              People

                weijun Weijun Wang
                kganapureddy Krushnareddy Ganapureddy
                Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: