8154976: UseSharedSpaces error message is incomplete
Reviewed-by: cjplummer, jiangli, mseledtsov
--- a/hotspot/src/share/vm/memory/filemap.cpp Wed Apr 27 16:02:32 2016 +0200
+++ b/hotspot/src/share/vm/memory/filemap.cpp Wed Apr 27 11:40:43 2016 -0700
@@ -99,7 +99,8 @@
fail(msg, ap);
} else {
if (PrintSharedSpaces) {
- tty->print_cr("UseSharedSpaces: %s", msg);
+ tty->print("UseSharedSpaces: ");
+ tty->vprint_cr(msg, ap);
}
}
UseSharedSpaces = false;
--- a/hotspot/test/runtime/CDSCompressedKPtrs/XShareAuto.java Wed Apr 27 16:02:32 2016 +0200
+++ b/hotspot/test/runtime/CDSCompressedKPtrs/XShareAuto.java Wed Apr 27 11:40:43 2016 -0700
@@ -67,6 +67,7 @@
// if sharing failed due to ASLR or similar reasons,
// check whether sharing was attempted at all (UseSharedSpaces)
output.shouldContain("UseSharedSpaces:");
+ output.shouldNotContain("Unable to map %s");
}
output.shouldHaveExitValue(0);
}