sanitycheck: Flush stdout in info()

This makes piped output work as the user expects. And looking at the
piped output is the only way to use sanitycheck normally because
of #4603.

Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
This commit is contained in:
Paul Sokolovsky 2017-10-27 14:53:24 +03:00 committed by Anas Nashif
parent a7fedb7073
commit 3ba0876a3f

View file

@ -245,6 +245,7 @@ log_file = None
# Debug Functions
def info(what):
sys.stdout.write(what + "\n")
sys.stdout.flush()
if log_file:
log_file.write(what + "\n")
log_file.flush()