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

XMLWordPrintable

    • 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);

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

                Created:
                Updated:
                Resolved: