[core] fix concurrency issues
* initialize first line of output earlier (before modules are initialized, so that module/thread output cannot interfere) * make sure that update and draw are protected against concurrent access
This commit is contained in:
parent
ee81f6198e
commit
ee9885a601
3 changed files with 18 additions and 10 deletions
|
@ -136,7 +136,6 @@ class Module(core.module.Module):
|
|||
core.event.trigger("update", [self.id], redraw_only=True)
|
||||
core.event.trigger("draw")
|
||||
os.set_blocking(proc.stdout.fileno(), False)
|
||||
time.sleep(0.5)
|
||||
proc.stdout.read()
|
||||
os.set_blocking(proc.stdout.fileno(), True)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue