kms: Don't reschedule rendering on inactive sessions

This commit is contained in:
Victoria Brekenfeld 2022-08-31 13:10:24 +02:00
parent 6690e13d54
commit e1894ef425

View file

@ -1004,6 +1004,7 @@ impl KmsState {
&device.render_node, &device.render_node,
&mut data.state.common, &mut data.state.common,
) { ) {
if backend.session.is_active() {
slog_scope::error!("Error rendering: {}", err); slog_scope::error!("Error rendering: {}", err);
return TimeoutAction::ToDuration(Duration::from_secs_f64( return TimeoutAction::ToDuration(Duration::from_secs_f64(
1.0 / surface.refresh_rate as f64, 1.0 / surface.refresh_rate as f64,
@ -1011,6 +1012,7 @@ impl KmsState {
} }
} }
} }
}
TimeoutAction::Drop TimeoutAction::Drop
}, },
)?); )?);