SDL: JNI_Unload must return the JNI version needed by the native library (f8252)

From f8252fcc916326e36057363ed1bd7c4a3c7a68b7 Mon Sep 17 00:00:00 2001
From: Anonymous Maarten <[EMAIL REDACTED]>
Date: Wed, 26 Nov 2025 13:44:29 +0100
Subject: [PATCH] JNI_Unload must return the JNI version needed by the native
 library

(cherry picked from commit eda8d1d8427c84bd27bfc5128173b0fc26cef173)
---
 src/core/SDL_core_unsupported.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/src/core/SDL_core_unsupported.c b/src/core/SDL_core_unsupported.c
index af963ed8f43a4..c7baea8ef87c6 100644
--- a/src/core/SDL_core_unsupported.c
+++ b/src/core/SDL_core_unsupported.c
@@ -207,7 +207,6 @@ Sint32 JNI_OnLoad(void *vm, void *reserved)
 {
     (void)vm;
     (void)reserved;
-    SDL_Unsupported();
-    return -1; // JNI_ERR
+    return 0x00010004; // JNI_VERSION_1_4
 }
 #endif

1 Like