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 755499 - popover: Fix crash when popover is NULL
popover: Fix crash when popover is NULL
Status: RESOLVED DUPLICATE of bug 746139
Product: gtk+
Classification: Platform
Component: .General
unspecified
Other All
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2015-09-23 21:28 UTC by Bastien Nocera
Modified: 2017-08-03 21:15 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
popover: Fix crash when popover is NULL (1.63 KB, patch)
2015-09-23 21:28 UTC, Bastien Nocera
none Details | Review

Description Bastien Nocera 2015-09-23 21:28:39 UTC
.
Comment 1 Bastien Nocera 2015-09-23 21:28:44 UTC
Created attachment 311987 [details] [review]
popover: Fix crash when popover is NULL

When the popover was NULL, we'd access invalid memory before the
g_return_if_fail guards.
Comment 2 Matthias Clasen 2015-09-23 23:22:47 UTC
hitting the g_return_if_fail is as good as a crash, so this makes little practical difference.
Comment 3 Bastien Nocera 2015-09-23 23:39:36 UTC
(In reply to Matthias Clasen from comment #2)
> hitting the g_return_if_fail is as good as a crash, so this makes little
> practical difference.

Except that it will actually be showing as a g_return_if_fail() in the stack traces, instead of null pointers dereferences.
Comment 4 Bastien Nocera 2015-09-23 23:41:03 UTC
Or put a g_assert() here if the intent is crashing.
Comment 5 Daniel Boles 2017-08-03 21:14:32 UTC
Timm fixed this in commit 0d17421ffdc3b6d3d47eaa38791f84e6111fe3f0
Comment 6 Daniel Boles 2017-08-03 21:15:45 UTC

*** This bug has been marked as a duplicate of bug 746139 ***