Proper fix for screen freeze
If an X event is received at a very specific point in time, it can trigger a race condition in Xlib. Said event will be read, but Xlib will nonetheless be completely unaware of the event. This cause compton to sometimes block on select() while there are events ready to be processed. If the event is a damage report, screen freeze will happen until some other event is received. The proper fix is to switch to xcb for event handling, thus avoid this problem entirely.
This commit is contained in:
@ -332,14 +332,6 @@ ms_to_tv(int timeout) {
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
* Whether an event is DamageNotify.
|
||||
*/
|
||||
static inline bool
|
||||
isdamagenotify(session_t *ps, const XEvent *ev) {
|
||||
return ps->damage_event + XDamageNotify == ev->type;
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a XTextProperty of a single string.
|
||||
*/
|
||||
|
Reference in New Issue
Block a user