This commit is contained in:
Spartan322
2025-04-19 07:12:16 -04:00
5209 changed files with 229124 additions and 66199 deletions

View File

@@ -30,8 +30,7 @@
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
/**************************************************************************/
#ifndef JNI_UTILS_H
#define JNI_UTILS_H
#pragma once
#include "thread_jandroid.h"
@@ -93,11 +92,9 @@ static inline String jstring_to_string(jstring source, JNIEnv *env = nullptr) {
}
const char *const source_utf8 = env->GetStringUTFChars(source, nullptr);
if (source_utf8) {
result.parse_utf8(source_utf8);
result.append_utf8(source_utf8);
env->ReleaseStringUTFChars(source, source_utf8);
}
}
return result;
}
#endif // JNI_UTILS_H