fix JNI float argument passing

Floats are implicitly promoted to doubles when passed as part of a
variable-length argument list, so we can't treat them the same way as
32-bit integers.
This commit is contained in:
Joel Dice 2012-02-28 15:35:28 -07:00
parent c6ac66e45a
commit 5a5d2a8dd2

View File

@ -8037,10 +8037,17 @@ class ArgumentList {
break;
case 'J':
case 'D':
addLong(va_arg(arguments, uint64_t));
break;
case 'D':
addLong(doubleToBits(va_arg(arguments, double)));
break;
case 'F':
addInt(floatToBits(va_arg(arguments, double)));
break;
default:
addInt(va_arg(arguments, uint32_t));
break;