win: demote log_error in win_clear_flags

Flags might be cleared on a destroyed window, if it's set because of an
event received before the window is destroyed.

Eventually we want to delay the handling of destroy notify as well.

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
This commit is contained in:
Yuxuan Shui 2020-04-11 02:39:20 +01:00
parent 018294a65c
commit f8f1758137
No known key found for this signature in database
GPG Key ID: 37C999F617EA1A47
1 changed files with 2 additions and 2 deletions

View File

@ -2351,7 +2351,7 @@ void win_set_flags(struct managed_win *w, uint64_t flags) {
void win_clear_flags(struct managed_win *w, uint64_t flags) {
log_debug("Clear flags %lu from window %#010x (%s)", flags, w->base.id, w->name);
if (unlikely(w->state == WSTATE_DESTROYING)) {
log_error("Flags cleared on a destroyed window %#010x (%s)", w->base.id,
log_warn("Flags cleared on a destroyed window %#010x (%s)", w->base.id,
w->name);
return;
}