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 748196 - Fix converting pointer to gtype
Fix converting pointer to gtype
Status: RESOLVED FIXED
Product: gom
Classification: Other
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Gom Maintainers
Gom Maintainers
: 741099 741637 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2015-04-20 16:02 UTC by Heiher
Modified: 2015-04-27 11:16 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Fix converting pointer to GType (2.36 KB, patch)
2015-04-20 16:04 UTC, Heiher
committed Details | Review

Description Heiher 2015-04-20 16:02:37 UTC
On 64-bit system, The GType is an eight-byte type. so, if we converting a GType to pointer, GINT_TO_POINTER (aka (gpointer) (gulong) (i)) is no problem. but, if we want to converting pointer back to GType, GPOINTER_TO_INT (aka (gint) (glong) (i)) is not work.

I think we should converting pointer to GType by "(GType) xxxx".
Comment 1 Heiher 2015-04-20 16:04:44 UTC
Created attachment 302010 [details] [review]
Fix converting pointer to GType
Comment 2 Bastien Nocera 2015-04-21 13:36:54 UTC
We already have a patch for that in bug 741099, which breaks the API.
Comment 3 Bastien Nocera 2015-04-21 13:37:32 UTC
I guess that we should test whether your patch fixes the bug in bug 741099.
Comment 4 Bastien Nocera 2015-04-21 23:39:01 UTC
*** Bug 741099 has been marked as a duplicate of this bug. ***
Comment 5 Bastien Nocera 2015-04-27 11:16:40 UTC
*** Bug 741637 has been marked as a duplicate of this bug. ***