diff options
author | Jacob Kroon <jacob.kroon@gmail.com> | 2016-08-05 00:04:26 +0200 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-08-10 10:45:13 +0100 |
commit | 314937429d700204f296cfd1c0c5f215a2e5b939 (patch) | |
tree | 856080d9155e7829ca20d9dc9bdafd5b99ff51c6 | |
parent | c2991efb6f4894061ee99b62cef4024be51dcdbf (diff) | |
download | openembedded-core-314937429d700204f296cfd1c0c5f215a2e5b939.tar.gz openembedded-core-314937429d700204f296cfd1c0c5f215a2e5b939.tar.bz2 openembedded-core-314937429d700204f296cfd1c0c5f215a2e5b939.zip |
terminal: Add sleep in pid-monitor loop
Monitoring the process started by gnome-terminal was
spinning in a busy-loop. Insert some sleeping so that
we don't eat all the cpu.
Signed-off-by: Jacob Kroon <jacob.kroon@gmail.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
-rw-r--r-- | meta/lib/oe/terminal.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/meta/lib/oe/terminal.py b/meta/lib/oe/terminal.py index 6d6a29f983..3901ad3f26 100644 --- a/meta/lib/oe/terminal.py +++ b/meta/lib/oe/terminal.py @@ -76,9 +76,11 @@ class Gnome(XTerminal): finally: os.unlink(pidfile) + import time while True: try: os.kill(pid, 0) + time.sleep(0.1) except OSError: return |