]> code.ossystems Code Review - openembedded-core.git/commitdiff
runqemu: do not check return code of tput
authorChen Qi <Qi.Chen@windriver.com>
Fri, 12 Apr 2019 01:40:06 +0000 (09:40 +0800)
committerArmin Kuster <akuster808@gmail.com>
Tue, 23 Apr 2019 00:25:02 +0000 (18:25 -0600)
The subprocess.run was replaced by subprocess.check_call because
of compatibility support down to python 3.4. But we really don't
care about whether that command succeeds. Some user reports that
in some tmux environment, this command fails and gives some
unpleasant traceback output. So we use 'call' instead of 'check_call'
to avoid such problem.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
scripts/runqemu

index 1c96b29a406d8cca3c0c9e0fa5e753905d4003ac..f83e05728b1dd0331630da61f022a0ad7961b3e4 100755 (executable)
@@ -1333,7 +1333,8 @@ def main():
             logger.info("SIGTERM received")
             os.kill(config.qemupid, signal.SIGTERM)
             config.cleanup()
-            subprocess.check_call(["tput", "smam"])
+            # Deliberately ignore the return code of 'tput smam'.
+            subprocess.call(["tput", "smam"])
         signal.signal(signal.SIGTERM, sigterm_handler)
 
         config.check_args()
@@ -1355,7 +1356,8 @@ def main():
         return 1
     finally:
         config.cleanup()
-        subprocess.check_call(["tput", "smam"])
+        # Deliberately ignore the return code of 'tput smam'.
+        subprocess.call(["tput", "smam"])
 
 if __name__ == "__main__":
     sys.exit(main())