bamf matcher messes up refcounting on views
Bug #942070 reported by
Allison Karlitskaya
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
BAMF |
Fix Released
|
High
|
Allison Karlitskaya | ||
Unity |
Fix Released
|
High
|
Allison Karlitskaya | ||
bamf (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned | ||
unity (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
when a "Opened" signal comes from bamf, the client side matcher gets the view for the path and refs it. on "Closed" it unrefs it.
the problem comes when you close a window that was open when the application using bamf started running. in that case, the client library sees "Closed" with no "Opened" and drops a reference that it doesn't own.
see the attached test program for a simple demonstration of the problem. open a window, run the test program, then close the window.
Related branches
lp:~desrt/bamf/refcount-fix
- Marco Trevisan (Treviño): Approve
-
Diff: 22 lines (+1/-4)1 file modifiedlib/libbamf/bamf-matcher.c (+1/-4)
Changed in bamf: | |
status: | New → In Progress |
importance: | Undecided → Medium |
importance: | Medium → High |
Changed in unity: | |
milestone: | none → 5.6.0 |
status: | New → In Progress |
importance: | Undecided → High |
Changed in bamf: | |
assignee: | nobody → Ryan Lortie (desrt) |
Changed in unity: | |
assignee: | nobody → Ryan Lortie (desrt) |
Changed in bamf: | |
status: | In Progress → Fix Committed |
Changed in unity: | |
status: | In Progress → Fix Committed |
Changed in bamf: | |
status: | Fix Committed → Fix Released |
Changed in unity: | |
status: | Fix Committed → Fix Released |
no longer affects: | bamf (Ubuntu Quantal) |
Changed in unity (Ubuntu): | |
status: | New → Fix Released |
To post a comment you must log in.
this patch fixes the bug for me.
i'm not sure why the matcher wants to hold an extra ref on the view -- the view factory holds a ref in it with its hashtable already. i tested this patch and it works for me, but i may have missed something.