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 702047 - obsolete power notifications shown in message tray
obsolete power notifications shown in message tray
Status: RESOLVED FIXED
Product: gnome-settings-daemon
Classification: Core
Component: power
unspecified
Other Linux
: Normal normal
: ---
Assigned To: gnome-settings-daemon-maint
gnome-settings-daemon-maint
: 704566 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2013-06-11 23:05 UTC by Allan Day
Modified: 2013-07-19 15:57 UTC
See Also:
GNOME target: ---
GNOME version: 3.7/3.8


Attachments
power: Fix non-transient notifications sticking around (7.03 KB, patch)
2013-06-12 11:42 UTC, Bastien Nocera
committed Details | Review

Description Allan Day 2013-06-11 23:05:11 UTC
I've seen this a couple of times in the past week, running GNOME 3.8.2 on Fedora 19. In one instance I had three low power notifications in my tray:

https://bug687828.bugzilla-attachments.gnome.org/attachment.cgi?id=246371

In another case I had a critical power notification in there.
Comment 1 Bastien Nocera 2013-06-12 11:42:41 UTC
Created attachment 246613 [details] [review]
power: Fix non-transient notifications sticking around

When replacing an existing notification with a more up-to-date one,
we were closing the existing notification, and creating a new one in its
place. As, to clean up when a notification is dismissed by hand, we hook
up to the "closed" signal, we ended up zero'ing the pointer to the just
shown notification and making it impossible to remove later.

eg.
- 1st notification created
- updated state comes in
- notify_close() called
- notification pointer is replaced with newer notification
- main loop returns
- "closed" signal is received for the 1st notification (ah!)
- original notification is unref'ed, and its location is zero'd
  by weak pointer call.

That location is that of the new notification as well.
Comment 2 Bastien Nocera 2013-06-12 13:33:34 UTC
Pushed to gnome-3-8 and master

A fix to https://bugs.launchpad.net/bugs/1190209 would be necessary to add it to the test suite

Attachment 246613 [details] pushed as 487ab6c - power: Fix non-transient notifications sticking around
Comment 3 Bastien Nocera 2013-07-19 15:57:59 UTC
*** Bug 704566 has been marked as a duplicate of this bug. ***