From ed6d993008cc6e08d910b21ae3f7f7b6c0558b5e Mon Sep 17 00:00:00 2001 From: yury Date: Wed, 23 Nov 2016 14:39:46 +0000 Subject: [PATCH] * pas2jni: Proper boolean handling - jboolean must be 0/1. git-svn-id: trunk@34954 - --- utils/pas2jni/writer.pas | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/pas2jni/writer.pas b/utils/pas2jni/writer.pas index 7b84716d31..ba33da540a 100644 --- a/utils/pas2jni/writer.pas +++ b/utils/pas2jni/writer.pas @@ -2236,7 +2236,7 @@ begin btString, btWideString: Result:=Format('_StringToJString(_env, _JNIString(%s))', [Result]); btBoolean: - Result:=Format('jboolean(LongBool(%s))', [Result]); + Result:=Format('(jboolean(%s) and 1)', [Result]); btChar: Result:=Format('jchar(widechar(%s))', [Result]); btWideChar: