After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 304870 - segfault on creating a gdk.Point
segfault on creating a gdk.Point
Status: VERIFIED FIXED
Product: java-gnome
Classification: Bindings
Component: GTK
mainline
Other Linux
: Normal normal
: ---
Assigned To: java-gnome bindings maintainers
java-gnome bindings maintainers
Depends on:
Blocks:
 
 
Reported: 2005-05-20 14:31 UTC by Yair Hershkovitz
Modified: 2009-08-15 18:40 UTC
See Also:
GNOME target: ---
GNOME version: 2.9/2.10


Attachments
fix for head branch (6.51 KB, patch)
2005-05-21 09:06 UTC, Yair Hershkovitz
none Details | Review
fix for 2-6 branch (6.38 KB, patch)
2005-05-21 09:06 UTC, Yair Hershkovitz
none Details | Review
fix for 2-6 branch (6.38 KB, patch)
2005-05-26 15:43 UTC, Yair Hershkovitz
none Details | Review

Description Yair Hershkovitz 2005-05-20 14:31:09 UTC
i'm having a segfault when running this: org.gnu.gdk.Point p = new
org.gnu.gdk.Point(0,0). for some reason the jni call to getPointerFromHandle
returns 1 instead of the pointer value (which is set correct in the Handle). 
this happens when Point ctor calles  setX(x)
Comment 1 Yair Hershkovitz 2005-05-21 09:06:20 UTC
Created attachment 46703 [details] [review]
fix for head branch

fix the jni bug in gdk.Point and the same bug in gdk.Rectangle

this fix also add: 1) default ctor for gdk.Point
		   2) user ctors for gdk.Rectangle
Comment 2 Yair Hershkovitz 2005-05-21 09:06:56 UTC
Created attachment 46704 [details] [review]
fix for 2-6 branch

fix the jni bug in gdk.Point and the same bug in gdk.Rectangle

this fix also add: 1) default ctor for gdk.Point
		   2) user ctors for gdk.Rectangle
Comment 3 Yair Hershkovitz 2005-05-26 15:43:17 UTC
Created attachment 46909 [details] [review]
fix for 2-6 branch

fixes another bug on point jni
Comment 4 Andrew Cowie 2005-05-28 01:16:13 UTC
Can you please post a small example class which exercised this code so I can
test your fixes? I don't have any code handy which uses these classes, so I
can't verify your patches.

AfC
Calgary
Comment 5 Nicholas Rahn 2005-05-28 15:42:44 UTC
Patch applied to branch 2_6, but without the API changes for Point and
Rectangle.  Unfortunately we can't make API modifs to this branch, only bug fixes.

Patch applied to CVS HEAD (including API changes).

Thanks for your contribution.  Sorry about the delay.
Comment 6 Ismael Juma 2005-05-28 15:59:57 UTC
I'm not sure whether there was much point in committing some of these changes
(namely finalizer and _new functions) as these are GBoxed and therefore should
use the framework introduced by the new memory management scheme.
Comment 7 Nicholas Rahn 2005-05-28 16:04:12 UTC
I think we can modify the finalizer code and handle creation once we know what
the final look of the GBoxed memory mgt stuff will be.