Avoid a crash caused by a race conditon
This commit is contained in:
parent
ea88cca35f
commit
5be50921d4
@ -86,6 +86,11 @@ pub const Output = struct {
|
|||||||
output.root.current_focused_tags,
|
output.root.current_focused_tags,
|
||||||
);
|
);
|
||||||
while (it.next()) |view| {
|
while (it.next()) |view| {
|
||||||
|
// This check prevents a race condition when a frame is requested
|
||||||
|
// between mapping of a view and the first configure being handled.
|
||||||
|
if (view.current_box.width == 0 or view.current_box.height == 0) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
output.renderView(view, &now);
|
output.renderView(view, &now);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user