diff --git a/test/hotspot/jtreg/serviceability/sa/TestClhsdbJstackLock.java b/test/hotspot/jtreg/serviceability/sa/TestClhsdbJstackLock.java index e4d4361e6512b..266b14167ef4e 100644 --- a/test/hotspot/jtreg/serviceability/sa/TestClhsdbJstackLock.java +++ b/test/hotspot/jtreg/serviceability/sa/TestClhsdbJstackLock.java @@ -59,7 +59,7 @@ public static void main (String... args) throws Exception { "^\\s+- waiting to lock <0x[0-9a-f]+> \\(a java\\.lang\\.Class for LingeredAppWithLock\\)$", "^\\s+- locked <0x[0-9a-f]+> \\(a java\\.lang\\.Thread\\)$", "^\\s+- locked <0x[0-9a-f]+> \\(a java\\.lang\\.Class for int\\)$", - "^\\s+- waiting on <0x[0-9a-f]+> \\(a java\\.lang\\.Object\\)$")); + "^\\s+- waiting on (<0x[0-9a-f]+> \\(a java\\.lang\\.Object\\)|)$")); unExpStrMap.put("jstack", List.of( "missing reason for ")); test.run(app.getPid(), cmds, expStrMap, unExpStrMap); diff --git a/test/hotspot/jtreg/serviceability/sa/TestJhsdbJstackLock.java b/test/hotspot/jtreg/serviceability/sa/TestJhsdbJstackLock.java index 98c4286609178..d3c7f61103165 100644 --- a/test/hotspot/jtreg/serviceability/sa/TestJhsdbJstackLock.java +++ b/test/hotspot/jtreg/serviceability/sa/TestJhsdbJstackLock.java @@ -65,7 +65,7 @@ public static void main (String... args) throws Exception { out.shouldMatch("^\\s+- waiting to lock <0x[0-9a-f]+> \\(a java\\.lang\\.Class for LingeredAppWithLock\\)$"); out.shouldMatch("^\\s+- locked <0x[0-9a-f]+> \\(a java\\.lang\\.Thread\\)$"); out.shouldMatch("^\\s+- locked <0x[0-9a-f]+> \\(a java\\.lang\\.Class for int\\)$"); - out.shouldMatch("^\\s+- waiting on <0x[0-9a-f]+> \\(a java\\.lang\\.Object\\)$"); + out.shouldMatch("^\\s+- waiting on (<0x[0-9a-f]+> \\(a java\\.lang\\.Object\\)|)$"); out.stderrShouldBeEmptyIgnoreDeprecatedWarnings();