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 661921 - PlacesManager: block-scoped monitor on ~/.gtk-bookmarks is wrong
PlacesManager: block-scoped monitor on ~/.gtk-bookmarks is wrong
Status: RESOLVED FIXED
Product: gnome-shell
Classification: Core
Component: general
3.2.x
Other Linux
: Normal normal
: ---
Assigned To: gnome-shell-maint
gnome-shell-maint
Depends on:
Blocks:
 
 
Reported: 2011-10-16 16:40 UTC by Stefan "psYchotic" Zwanenburg
Modified: 2011-10-18 18:04 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
PlacesManager: fix ~/.gtk-bookmarks monitoring (1.51 KB, patch)
2011-10-16 16:40 UTC, Stefan "psYchotic" Zwanenburg
committed Details | Review

Description Stefan "psYchotic" Zwanenburg 2011-10-16 16:40:42 UTC
Created attachment 199133 [details] [review]
PlacesManager: fix ~/.gtk-bookmarks monitoring

The PlacesManager class is defined in the js/ui/placeDisplay.js. There we find that upon construction of a PlacesManager, a GFileMonitor is created to watch for changes in the ~/.gtk-bookmarks file.
Unfortunately, the variable that holds this monitor is block-scoped, which causes it to be destroyed as soon as the PlacesManager._init() function returns. This in turn makes the monitoring of ~/.gtk-bookmarks a problem.

Please find attached a patch that attempts to fix this problem.
Comment 1 Jasper St. Pierre (not reading bugmail) 2011-10-16 18:13:35 UTC
Review of attachment 199133 [details] [review]:

Makes sense.
Comment 2 Jasper St. Pierre (not reading bugmail) 2011-10-18 17:16:17 UTC
Do you not have a GNOME Git account?
Comment 3 Stefan "psYchotic" Zwanenburg 2011-10-18 17:53:22 UTC
Nope, I do not. Why?
Comment 4 Jasper St. Pierre (not reading bugmail) 2011-10-18 18:00:06 UTC
(In reply to comment #3)
> Nope, I do not. Why?

Because it's marked as accepted-commit_now, which means you can push it. But since you don't have an account, I'll push for you.
Comment 5 Jasper St. Pierre (not reading bugmail) 2011-10-18 18:04:49 UTC
Thanks for the patch!