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

test/lib/containers/docker/DockerRunOptions.java uses addJavaOpts() from ctor

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • 25
    • 25
    • hotspot
    • None
    • b03

      Class
        public DockerRunOptions(String imageNameAndTag, String javaCmd,
                                  String classToRun, String... javaOpts) {
              this.imageNameAndTag = imageNameAndTag;
              this.command = javaCmd;
              this.classToRun = classToRun;
              this.addJavaOpts(javaOpts);
              // always print hserr to stderr in the docker tests to avoid
              // trouble accessing it after a crash in the container
              this.addJavaOpts("-XX:+ErrorFileToStderr");
          }

      run addJavaOpts from ctor

      The warning is
      /home/lmesnik/ws/jdk-lib/open/test/lib/jdk/test/lib/containers/docker/DockerRunOptions.java:62: warning: [this-escape] possible 'this' escape before subclass is fully initialized
              this.addJavaOpts(javaOpts);

            lmesnik Leonid Mesnik
            lmesnik Leonid Mesnik
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: