Skip to content

Commit

Permalink
8307347: serviceability/sa/ClhsdbDumpclass.java could leave files own…
Browse files Browse the repository at this point in the history
…ed by root on macOS

Backport-of: 5c7ede94ae59b46c12d40a38bf5b7e15319cc7e2
  • Loading branch information
ArnoZeller authored and MBaesken committed May 25, 2023
1 parent 861fe74 commit 50aabaa
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions test/hotspot/jtreg/serviceability/sa/ClhsdbDumpclass.java
Expand Up @@ -31,6 +31,7 @@
import jdk.test.lib.apps.LingeredApp;
import jdk.test.lib.JDKToolLauncher;
import jdk.test.lib.process.OutputAnalyzer;
import jdk.test.lib.SA.SATestUtils;
import jtreg.SkippedException;

/**
Expand All @@ -47,6 +48,10 @@ public class ClhsdbDumpclass {
static final String APP_SLASH_CLASSNAME = APP_DOT_CLASSNAME.replace('.', '/');

public static void main(String[] args) throws Exception {
if (SATestUtils.needsPrivileges()) {
// This test will create a file as root that cannot be easily deleted, so don't run it.
throw new SkippedException("Cannot run this test on OSX if adding privileges is required.");
}
System.out.println("Starting ClhsdbDumpclass test");

LingeredApp theApp = null;
Expand Down

1 comment on commit 50aabaa

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.