0
0
mirror of https://github.com/termux/termux-packages.git synced 2024-12-13 01:50:33 +00:00
termux-packages/packages/openjdk-21/0009-Use-Android-s-strerror_r.patch
eval Nya 940a37f5f0 addpkg(main/openjdk-21): 21.0.3-ga
cherry-pick all patches, apply them on upstream JDK, and adapted for
newer $UPDATE version

fix: type redefinition introduced in 21.0.2
2024-10-17 14:02:06 +02:00

31 lines
1.0 KiB
Diff

From 13a958a7686ad1a813f5b2f56b11351db64d2d98 Mon Sep 17 00:00:00 2001
From: Duy Tran Khanh <40482367+khanhduytran0@users.noreply.github.com>
Date: Thu, 10 Jun 2021 09:36:26 +0700
Subject: [PATCH 09/37] Use Android's strerror_r()
---
src/java.base/unix/native/libjava/jni_util_md.c | 7 -------
1 file changed, 7 deletions(-)
diff --git a/src/java.base/unix/native/libjava/jni_util_md.c b/src/java.base/unix/native/libjava/jni_util_md.c
index 32b477aa7..06d5501a8 100644
--- a/src/java.base/unix/native/libjava/jni_util_md.c
+++ b/src/java.base/unix/native/libjava/jni_util_md.c
@@ -31,13 +31,6 @@
#include "jni_util.h"
#include "dlfcn.h"
-#if defined(LINUX) && (defined(_GNU_SOURCE) || \
- (defined(_POSIX_C_SOURCE) && _POSIX_C_SOURCE < 200112L \
- && defined(_XOPEN_SOURCE) && _XOPEN_SOURCE < 600))
-extern int __xpg_strerror_r(int, char *, size_t);
-#define strerror_r(a, b, c) __xpg_strerror_r((a), (b), (c))
-#endif
-
void* getProcessHandle() {
static void *procHandle = NULL;
if (procHandle != NULL) {
--
2.45.2