aboutsummaryrefslogtreecommitdiffhomepage
path: root/patches/server/0662-Remove-client-side-code-using-deprecated-for-removal.patch
diff options
context:
space:
mode:
Diffstat (limited to 'patches/server/0662-Remove-client-side-code-using-deprecated-for-removal.patch')
-rw-r--r--patches/server/0662-Remove-client-side-code-using-deprecated-for-removal.patch11
1 files changed, 5 insertions, 6 deletions
diff --git a/patches/server/0662-Remove-client-side-code-using-deprecated-for-removal.patch b/patches/server/0662-Remove-client-side-code-using-deprecated-for-removal.patch
index 2ed18ebaeb..b7a4fc1608 100644
--- a/patches/server/0662-Remove-client-side-code-using-deprecated-for-removal.patch
+++ b/patches/server/0662-Remove-client-side-code-using-deprecated-for-removal.patch
@@ -7,24 +7,23 @@ Subject: [PATCH] Remove client-side code using deprecated for removal
Fixes warnings on build
diff --git a/src/main/java/net/minecraft/Util.java b/src/main/java/net/minecraft/Util.java
-index 765e4bc00a0526aab6e263dae7233f63f7f31498..edf937591abf62416bd692e40b7b7a6badbe877d 100644
+index 722734ce612fb790ddc80488a795a85ebcd4a842..72e734af483dc03e1ae947b2ab3b6fa7df38ce62 100644
--- a/src/main/java/net/minecraft/Util.java
+++ b/src/main/java/net/minecraft/Util.java
-@@ -951,17 +951,7 @@ public class Util {
+@@ -935,16 +935,7 @@ public class Util {
}
public void openUrl(URL url) {
- try {
-- Process process = AccessController.doPrivileged((PrivilegedExceptionAction<Process>)(() -> {
-- return Runtime.getRuntime().exec(this.getOpenUrlArguments(url));
-- }));
+- Process process = AccessController.doPrivileged(
+- (PrivilegedExceptionAction<Process>)(() -> Runtime.getRuntime().exec(this.getOpenUrlArguments(url)))
+- );
- process.getInputStream().close();
- process.getErrorStream().close();
- process.getOutputStream().close();
- } catch (IOException | PrivilegedActionException var3) {
- Util.LOGGER.error("Couldn't open url '{}'", url, var3);
- }
--
+ throw new IllegalStateException("This method is not useful on dedicated servers."); // Paper - Fix warnings on build by removing client-only code
}