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 671601 - Access on unreffed pointer
Access on unreffed pointer
Status: RESOLVED FIXED
Product: mutter
Classification: Core
Component: general
git master
Other Linux
: Normal critical
: ---
Assigned To: mutter-maint
mutter-maint
Depends on:
Blocks:
 
 
Reported: 2012-03-07 21:39 UTC by Lionel Landwerlin
Modified: 2012-03-19 17:03 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch v1 (861 bytes, patch)
2012-03-07 21:39 UTC, Lionel Landwerlin
committed Details | Review

Description Lionel Landwerlin 2012-03-07 21:39:50 UTC
Created attachment 209218 [details] [review]
Patch v1

In meta_screen_remove_workspace function, after having called meta_workspace_remove which unref the workspace pointer, we still use workspace->screen.

Turned out to segfault on a setups.

Attached is a patch to remove this unreffed pointer access.
Comment 1 Owen Taylor 2012-03-08 21:06:27 UTC
(Note on this being marked critical and targeted to 3.4 - this has no effect when remove_workspace() is called from Javascript since that will hold a reference to the workspace object.)
Comment 2 Owen Taylor 2012-03-08 21:09:31 UTC
Review of attachment 209218 [details] [review]:

Looks good
Comment 3 Matthias Clasen 2012-03-18 02:04:29 UTC
Florian, should we get this in for 3.4 ?
Comment 4 Jasper St. Pierre (not reading bugmail) 2012-03-18 02:08:27 UTC
(In reply to comment #3)
> Florian, should we get this in for 3.4 ?

As Owen says, it doesn't matter for GNOME Shell 3.4 -- JS will always have a reference to the object. It's still a bug, but it shouldn't matter if it slips through the cracks.
Comment 5 Matthias Clasen 2012-03-19 13:28:58 UTC
but there's no need for it to slip through, right ? we have a patch, it is marked a-c-n, all we need is somebody to commit it...
Comment 6 Lionel Landwerlin 2012-03-19 14:12:30 UTC
I happen to have the right to commit (if nobody is willing to do it). :)
Comment 7 Jasper St. Pierre (not reading bugmail) 2012-03-19 14:26:16 UTC
"accepted-commit_now" means "please use your commit rights"
Comment 8 Florian Müllner 2012-03-19 14:27:46 UTC
Go ahead then :)
Comment 9 Lionel Landwerlin 2012-03-19 15:00:24 UTC
Ok done.
Comment 10 André Klapper 2012-03-19 17:03:28 UTC
Comment on attachment 209218 [details] [review]
Patch v1

[Updating patch status]