fix: drain all dmabufs

This commit is contained in:
Nova
2022-12-08 05:40:54 -05:00
parent 60baabb850
commit ac5e949614

View File

@@ -154,7 +154,7 @@ impl Wayland {
.and_then(|surf| surf.client()) .and_then(|surf| surf.client())
.map(|c| c.id()) else { continue }; .map(|c| c.id()) else { continue };
let mut state = self.state.lock(); let mut state = self.state.lock();
for dmabuf in state.pending_dmabufs.drain(1..) { for dmabuf in state.pending_dmabufs.drain(..) {
let _ = self.renderer.import_dmabuf(&dmabuf, None); let _ = self.renderer.import_dmabuf(&dmabuf, None);
} }
let Some(seat_data) = state.seats.get(&client_id).cloned() else { continue }; let Some(seat_data) = state.seats.get(&client_id).cloned() else { continue };