aboutsummaryrefslogtreecommitdiffhomepage
path: root/io.c
diff options
context:
space:
mode:
authorlemon <lsof@mailbox.org>2025-12-11 12:28:40 +0100
committerlemon <lsof@mailbox.org>2025-12-11 12:28:55 +0100
commite7671ddf611be4ab62deb1b6e2d0d3862c75dec6 (patch)
treeba32d3a706904b2ca0525d963c4d77152d671528 /io.c
parentf6e34f84e14ac5f272cb31e28e2f023acf702a99 (diff)
driver: add -Werror
Diffstat (limited to 'io.c')
-rw-r--r--io.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/io.c b/io.c
index ab3499b..b2d4364 100644
--- a/io.c
+++ b/io.c
@@ -1072,8 +1072,9 @@ warn(const struct span *span, const char *fmt, ...)
{
va_list ap;
+ if (ccopt.werror) ++nerror;
va_start(ap, fmt);
- vdiag(span, DGWARN, fmt, ap);
+ vdiag(span, ccopt.werror ? DGERROR : DGWARN, fmt, ap);
va_end(ap);
}