windows: fix file editing

tornado's asnycio patch does not take nonexisting file descriptors very well,
so we need to catch errors here.
This commit is contained in:
Maximilian Hils 2021-10-11 18:27:39 +02:00
parent 9688618bbd
commit 82529d88f0

View File

@ -444,7 +444,10 @@ class Screen(BaseScreen, RealTerminal):
self._input_thread = None
for handle in self._current_event_loop_handles:
try:
event_loop.remove_watch_file(handle)
except KeyError:
pass
if self._input_timeout:
event_loop.remove_alarm(self._input_timeout)