Re: [PATCH v2] date: detect underflow when parsing dates with positive timezone offset
- From
- Phillip Wood <phillip.wood123@gmail.com>
- Date
- Jun 3, 2024, 14:13 UTC
- Message-ID
- <67c23773-21a4-4ad5-9b98-5e44578166dd@gmail.com>
- In-Reply-To
- <2d771a72-3021-46db-ac32-e008a7ace34c@gmail.com>
Hi darcy
On 03/06/2024 12:44, darcy wrote:
Show 5 quoted lines
>> Do we also want to check for overflows in the other direction (a large >> timestamp with a negative timezone offset)? > > Is this something people want added? I am happy to implement this if > so, though it wasn't my original intention.
I think if we're worried about the date overflowing in one direction it makes sense to fix overflows in the other direction at the same time especially as I think that the other case involves a signed integer overflow which is undefined behavior in C.
Best Wishes
Phillip