Skip to content
Permalink
Browse files
8272777: Clean up remaining AccessController warnings in test library
Reviewed-by: rriggs, sspitsyn
  • Loading branch information
Kevin Walls committed Feb 3, 2022
1 parent 5ab22e8 commit 63a00a0df24b154ef459936dbd69bcd2f0626235
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
@@ -159,6 +159,7 @@ public static void addPrivilegesIfNeeded(ProcessBuilder pb) {
* if we are root, so return true. Then return false for an expected denial
* if "ptrace_scope" is 1, and true otherwise.
*/
@SuppressWarnings("removal")
private static boolean canPtraceAttachLinux() throws IOException {
// SELinux deny_ptrace:
var deny_ptrace = Paths.get("/sys/fs/selinux/booleans/deny_ptrace");
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2019, 2021, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2019, 2022, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -71,6 +71,7 @@ private static boolean isSupported(Class<? extends InetAddress> addressType) {
}
}

@SuppressWarnings("removal")
private static <T> T runPrivilegedAction(Callable<T> callable) {
try {
PrivilegedExceptionAction<T> pa = () -> callable.call();
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2005, 2020, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2005, 2022, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -54,6 +54,7 @@ public SimpleSSLContext() throws IOException {
this(() -> "TLS");
}

@SuppressWarnings("removal")
private SimpleSSLContext(Supplier<String> protocols) throws IOException {
try {
final String proto = protocols.get();

1 comment on commit 63a00a0

@openjdk-notifier
Copy link

@openjdk-notifier openjdk-notifier bot commented on 63a00a0 Feb 3, 2022

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.