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 467612 - impl_accessibility_accessible_get_state should check result of atk_object_ref_state_set
impl_accessibility_accessible_get_state should check result of atk_object_ref...
Status: RESOLVED FIXED
Product: at-spi
Classification: Platform
Component: general
1.18.x
Other Solaris
: Normal normal
: ---
Assigned To: LiYan.Zhang
Li Yuan
: 421514 437958 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2007-08-17 10:44 UTC by Oliver Braun
Modified: 2007-09-13 02:36 UTC
See Also:
GNOME target: ---
GNOME version: 2.17/2.18


Attachments
avoid the unnecessary crash by replacing the funcion of g_assert ( ) (850 bytes, patch)
2007-08-20 10:15 UTC, LiYan.Zhang
committed Details | Review

Description Oliver Braun 2007-08-17 10:44:48 UTC
If an application specific implementation of atk_object_ref_state_set returns NULL, the code crashes in spi_state_set_new().

See http://www.openoffice.org/issues/show_bug.cgi?id=80589
Comment 1 Li Yuan 2007-08-20 05:48:55 UTC
Is there a reason that an object doesn't have a state_set?
Comment 2 Oliver Braun 2007-08-20 07:51:24 UTC
It is probably a bug, even though I think the documentation of AtkObject could be clearer (stating that NULL is not allowed as return value).

The correct approach seems to be to return a state_set with just "defunct" in it. However, IMHO libspi should not crash in this case.
Comment 3 Li Yuan 2007-08-20 09:04:26 UTC
Yes, I think it maybe too hard to use g_assert... g_return_val_if_fail is OK I think.
Comment 4 LiYan.Zhang 2007-08-20 10:15:27 UTC
Created attachment 93969 [details] [review]
avoid the unnecessary crash  by replacing the funcion of  g_assert ( )
Comment 5 Li Yuan 2007-09-13 02:33:43 UTC
*** Bug 421514 has been marked as a duplicate of this bug. ***
Comment 6 Li Yuan 2007-09-13 02:36:23 UTC
*** Bug 437958 has been marked as a duplicate of this bug. ***