From 98a3dd364739136329fe2b8f9cdeecf776fb17c9 Mon Sep 17 00:00:00 2001 From: Tavian Barnes Date: Sun, 4 Oct 2020 13:46:35 -0400 Subject: diag: New bfs_perror() function --- diag.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'diag.c') diff --git a/diag.c b/diag.c index 308b05d..66609e1 100644 --- a/diag.c +++ b/diag.c @@ -24,6 +24,10 @@ #include #include +void bfs_perror(const struct bfs_ctx *ctx, const char *str) { + bfs_error(ctx, "%s: %m.\n", str); +} + void bfs_error(const struct bfs_ctx *ctx, const char *format, ...) { va_list args; va_start(args, format); -- cgit v1.2.3