fmt: fix buffer sizes when printing durations
The ISO 8601 buffer for durations was sized for `SignedDuration::MIN`, but the longest output is a negative duration with 16 digits of hours and two digit minutes and seconds, e.g., `-PT2562047788015214H59M59.999999999S`, which is 36 bytes. Similarly, the friendly format buffer for `std::time::Duration` didn't account for the `+` prefix written by `Direction::ForceSign`. Fixes #654
This commit is contained in:
1 parent
e14c262673
commit
a580c0b437
3 files changed
+37
-5
No files matched your search
@@ -1,5 +1,15 @@
|
||||
# CHANGELOG
|
||||
|
||||
0.2.39 (TBD)
|
||||
============
|
||||
TODO
|
||||
|
||||
Bug fixes:
|
||||
|
||||
* [#654](https://github.com/BurntSushi/jiff/issues/654):
|
||||
Fixes a panic when printing some very large durations.
|
||||
|
||||
|
||||
0.2.38 (2026-10-06)
|
||||
===================
|
||||
This release updates Jiff's bundled copy of the [IANA Time Zone Database]
|
||||
|
||||
Reference in new issue
Block a user