BUG when passing double
I'm having trouble passing doubles between java and c. I have the following java and c functions.
publicstaticnativevoid test(double a,int b,int c );
JNIEXPORTvoid JNICALL Java_TestAlign_test (
JNIEnv *env,
jclass me,
jdouble a,
jint b,
jint c ){
printf("got: %f %i %i\n",a,b,c);
}
When i run the code the value that i passed in for b (in java) is in the c parameter (in c) ... the c code has garbage in b ... this only occurs with double's, if i change it to floats its fine.
I'm thinking its a 64 bit issue. i'm on a 64bit machine, the java libraries are 64 bit and the c code is being compiled as 64 bits so i'm not sure.
Do i just need to play with compiler options? has anyone had this before. i'm completely stumped.

