This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

this pointer off by one?

[Get raw message]

Very bizarre... I have a native method written in C++ using CNI, but
within the body of the method, all variable accesses end up accessing
a memory location four octets (32 bits) beyond the proper location.

For example, I have two members:

   jint foo;
   jint bar;

Reading from bar yields the value that my java code had written into
foo! Reading foo yields random garbage (foo is the first member
variable).

I can't get this to happen with a small example program, but I can
send you the whole source blob if you need to see it for yourself
(it's pretty big).

I'm using GCJ 3.0.2. Any ideas what might cause this?

  - a

-- 
If the Boston Tea Party happened today, our politicians would denounce
it as an act of Terrorism.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]