From 1475e6984a5db4afaf454a06a67071130e86dca7 Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Wed, 1 Nov 2017 19:19:21 -0700 Subject: [PATCH] Fixed bug 3917 - Android, issues with getManifestEnvironmentVariable Sylvain Some issue with this commit: https://hg.libsdl.org/SDL/rev/97387a8b88d3 There is a memory allocation missing. --- src/core/android/SDL_android.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/core/android/SDL_android.c b/src/core/android/SDL_android.c index 78ef776a1..04a5f245e 100644 --- a/src/core/android/SDL_android.c +++ b/src/core/android/SDL_android.c @@ -2121,6 +2121,7 @@ char *SDL_AndroidGetManifestEnvironmentVariable(const char *variableName) jstring jVariableName = (*env)->NewStringUTF(env, variableName); jstring jResult = (jstring)((*env)->CallStaticObjectMethod(env, mActivityClass, midGetManifestEnvironmentVariable, jVariableName)); + (*env)->DeleteLocalRef(env, jVariableName); if (jResult == NULL) { return NULL;