diff --git a/src/share/vm/services/management.cpp b/src/share/vm/services/management.cpp index 549622e9210e1696244c1e7f906c9ed410661be9..aeee6ca3e9f8a85e0f4e0ea391046515d6570f2c 100644 --- a/src/share/vm/services/management.cpp +++ b/src/share/vm/services/management.cpp @@ -2126,7 +2126,7 @@ JVM_ENTRY(jint, jmm_DumpHeap0(JNIEnv *env, jstring outputfile, jboolean live)) THROW_MSG_(vmSymbols::java_lang_NullPointerException(), "Output file name cannot be null.", -1); } - char* name = java_lang_String::as_utf8_string(on); + char* name = java_lang_String::as_platform_dependent_str(on, CHECK_(-1)); if (name == NULL) { THROW_MSG_(vmSymbols::java_lang_NullPointerException(), "Output file name cannot be null.", -1);