diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2022-11-08 10:34:22 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2022-11-08 11:08:03 +0200 |
commit | 3bc0fc4c4496c345c79734dcd6dc56d44119aebf (patch) | |
tree | d058018aaf35641e461e51c2c20d374fd0d1684c /libbuild2/diagnostics.cxx | |
parent | 84e6c7e62c9d1613af3cad81787b3f277d276140 (diff) |
Make process exit diagnostics consistent
In particular, we now always print error message on non-0 exit except
in cases where such exit is ignored.
Diffstat (limited to 'libbuild2/diagnostics.cxx')
-rw-r--r-- | libbuild2/diagnostics.cxx | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/libbuild2/diagnostics.cxx b/libbuild2/diagnostics.cxx index 9433cd8..110641a 100644 --- a/libbuild2/diagnostics.cxx +++ b/libbuild2/diagnostics.cxx @@ -347,8 +347,8 @@ namespace build2 close (const char* const* args, const process_exit& pe, uint16_t v, - const location& loc, - bool omit_normall) + bool omit_normal, + const location& loc) { tracer trace ("diag_buffer::close"); @@ -363,19 +363,12 @@ namespace build2 { // Note: see similar code in run_finish_impl(). // - if (omit_normall && pe.normal ()) + if (omit_normal && pe.normal ()) { l4 ([&]{trace << "process " << args[0] << " " << pe;}); } else { - // It's unclear whether we should print this only if printing the - // command line (we could also do things differently for - // normal/abnormal exit). Let's print this always and see how it - // wears. - // - // Note: make sure keep the above trace is not printing. - // dr << error (loc) << "process " << args[0] << " " << pe; if (verb >= 1 && verb <= v) |