hotspot/src/share/vm/runtime/arguments.cpp
changeset 42636 aafc434ba580
parent 42620 a6f74efe32aa
child 42647 d01f2abf2c65
--- a/hotspot/src/share/vm/runtime/arguments.cpp	Mon Dec 05 18:00:34 2016 +0000
+++ b/hotspot/src/share/vm/runtime/arguments.cpp	Mon Dec 05 16:08:20 2016 -0500
@@ -25,6 +25,7 @@
 #include "precompiled.hpp"
 #include "classfile/classLoader.hpp"
 #include "classfile/javaAssertions.hpp"
+#include "classfile/moduleEntry.hpp"
 #include "classfile/stringTable.hpp"
 #include "classfile/symbolTable.hpp"
 #include "code/codeCacheExtensions.hpp"
@@ -3427,9 +3428,9 @@
   // This check is only required for java.base, all other duplicate module specifications
   // will be checked during module system initialization.  The module system initialization
   // will throw an ExceptionInInitializerError if this situation occurs.
-  if (strcmp(module_name, "java.base") == 0) {
+  if (strcmp(module_name, JAVA_BASE_NAME) == 0) {
     if (*patch_mod_javabase) {
-      vm_exit_during_initialization("Cannot specify java.base more than once to --patch-module");
+      vm_exit_during_initialization("Cannot specify " JAVA_BASE_NAME " more than once to --patch-module");
     } else {
       *patch_mod_javabase = true;
     }