awesome crashes when non-focused client exits/dies

When a non-focused client exits (e.g. through a signal) then awesome
crashes. The attached patch fixes this for me.

Cheers.

\n\n
This commit is contained in:
Nikos Ntarmos 2007-12-15 09:06:20 +02:00 committed by Julien Danjou
parent 69ba990371
commit e205a144cc
1 changed files with 6 additions and 2 deletions

View File

@ -83,8 +83,12 @@ focus_add_client(FocusList **head, Client *c)
void
focus_delete_client(FocusList **head, Client *c)
{
FocusList *target = focus_detach_node(head, focus_get_node_by_client(*head, c));
p_delete(&target);
FocusList *fc = focus_get_node_by_client(*head, c), *target;
if (fc)
{
target = focus_detach_node(head, fc);
p_delete(&target);
}
}
Client *