Fix bug in keybindings reload on MappingNotify.

This could cause deletion of random timers and result in general grief.

SVN revision: 39623
This commit is contained in:
Kim Woelders 2009-03-22 12:40:23 +00:00
parent b21bb1985b
commit 290c4d8432
1 changed files with 3 additions and 2 deletions

View File

@ -1103,18 +1103,19 @@ ActionclassesGlobalEvent(XEvent * ev)
return match;
}
static Timer *ac_reload_timer = NULL;
static int
_ac_reload(void *data __UNUSED__)
{
AclassConfigLoadConfig("bindings.cfg");
ac_reload_timer = NULL;
return 0;
}
void
ActionclassesReload(void)
{
static Timer *ac_reload_timer = NULL;
TIMER_DEL(ac_reload_timer);
TIMER_ADD(ac_reload_timer, 0.2, _ac_reload, NULL);
}