virtual_sdcard: Check if other events need to run after each file read

Periodically check if other events need to run - this prevents the
virtual_sdcard processing from starving other events.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor 2018-08-02 20:27:34 -04:00
parent f2d232ef77
commit 82738955d2
1 changed files with 1 additions and 0 deletions

View File

@ -160,6 +160,7 @@ class VirtualSD:
lines[0] = partial_input + lines[0]
partial_input = lines.pop()
lines.reverse()
self.reactor.pause(self.reactor.NOW)
continue
# Dispatch command
try: