summaryrefslogtreecommitdiff
path: root/sys/src
diff options
context:
space:
mode:
authorOri Bernstein <ori@eigenstate.org>2022-10-29 18:19:47 +0000
committerOri Bernstein <ori@eigenstate.org>2022-10-29 18:19:47 +0000
commit7d108832528eb1ee85a445a562c00b5a8344d882 (patch)
tree4381019545e7bdc9ca0ce67120a91c2bda66d464 /sys/src
parentc67a1784cc34ffec633b61ad3267e13d162be219 (diff)
tmdate: provide better parse errors
it's often not obvious what date component caused an error when eyeballing a date format string and date; make the error message contain this information.
Diffstat (limited to 'sys/src')
-rw-r--r--sys/src/libc/port/date.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/src/libc/port/date.c b/sys/src/libc/port/date.c
index c9526dec6..cf532cb8e 100644
--- a/sys/src/libc/port/date.c
+++ b/sys/src/libc/port/date.c
@@ -985,7 +985,7 @@ Zoneparsed:
tmtimens(tm, abs, tm->nsec, tz);
return tm;
baddate:
- werrstr("invalid date %s", str);
+ werrstr("invalid %c component in '%s'", c0, str);
return nil;
badfmt:
werrstr("garbled format %s near '%s'", fmt, p);