[PATCH 0/4] usage.c: add a non-fatal bug() + misc doc fixes
- From
Ævar Arnfjörð Bjarmason <avarab@gmail.com>
- Date
- Mar 28, 2021, 02:25 UTC
- Message-ID
- <cover-0.5-00000000000-20210328T022343Z-avarab@gmail.com>
Fix up some of the technical docs around error handling and add a bug() function, as explained in 4/4 this is for use in some fsck-related code.
This series does not make use of it, but I'll follow-up with one that does. I wanted to peel of this small cleanup series from that.
I noticed some semi-related bugs in these error tracing functions to do with the trace2 integration, noted in https://lore.kernel.org/git/87mtuoo4ym.fsf@evledraar.gmail.com/ this doesn't attempt to fix those.
Ævar Arnfjörð Bjarmason (4): usage.c: don't copy/paste the same comment three times api docs: document BUG() in api-error-handling.txt api docs: document that BUG() emits a trace2 error event usage.c: add a non-fatal bug() function to go with BUG()
.../technical/api-error-handling.txt | 16 ++++++- Documentation/technical/api-trace2.txt | 4 +- git-compat-util.h | 3 ++ run-command.c | 11 +++++ t/helper/test-trace2.c | 14 +++++- t/t0210-trace2-normal.sh | 19 ++++++++ usage.c | 46 ++++++++++++++----- 7 files changed, 95 insertions(+), 18 deletions(-)
-- 2.31.1.445.g91d8e479b0a