Opened 11 years ago
Closed 7 years ago
#10885 closed bug (fixed)
[PowerStatus] crashes Deskbar
Reported by: | diver | Owned by: | nobody |
---|---|---|---|
Priority: | normal | Milestone: | R1 |
Component: | Applications/PowerStatus | Version: | R1/Development |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Platform: | All |
Description
- Install PowerStatus replicant
- Open Battery info window
- Quit replicant
Attachments (2)
Change History (8)
by , 11 years ago
Attachment: | Deskbar-265-debug-30-05-2014-09-47-13.report added |
---|
comment:1 by , 11 years ago
comment:2 by , 8 years ago
After some experimentation, it seems the crash occurs because the PowerStatusReplicant destructor stops and releases the reference of the DriverInterface while the extended battery info window is still using it.
If _Quit() is modified to always close the battery information window before removing the replicant from the deskbar, the deskbar no longer crashes under the specified conditions.
However, with this modification, PowerStatus still crashes in a different situation, presumably for the same reason. Steps to reproduce:
- Open the PowerStatus applet and specify to Run in window
- Drag, using the bottom-right corner, the replicant to the desktop
- Close the PowerStatus window (not the replicant)
- Right-click the battery icon on the replicant and select "Battery info...", leave the window open.
- Right-click the dragger on the bottom-right of the replicant and select "Remove replicant.". The Tracker will crash.
I'm not sure how to solve this last problem as _Quit() is not called in this situation (in fact, using the "Quit" option provided by PowerStatus won't work when it is a stand-alone replicant). Perhaps some message (that is not B_QUIT_REQUESTED) will be sent to the replicant before it is closed, or the code I added to close the window can be safely moved to the destructor?
I'll submit a patch but it is certainly not the ideal solution.
by , 8 years ago
Attachment: | 0001-PowerStatus-close-extended-info-window-on-quit.patch added |
---|
comment:3 by , 8 years ago
patch: | 0 → 1 |
---|
comment:4 by , 8 years ago
I would go with a deeper re-strucuration of PowerStatus.
The extended info window should be started in its own dedicated team, not inside Tracker's or DeskBar's one. So, the replicant should open it by launching the main app. This way the replicant and the window can live independantly.
comment:5 by , 8 years ago
Owner: | changed from | to
---|---|
Status: | new → assigned |
I wonder if this crash always happens, or does it only happen on systems with a battery?