Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | timespec-sub: fix overflow bug; add tests | Paul Eggert | 2015-11-05 | 1 | -0/+16 |
* lib/timespec-add.c (timespec_add): * lib/timespec-sub.c (timespec_sub): Work even if time_t is narrower than int (a theoretical possibility). Redo code for a bit more clarity. * lib/timespec-sub.c (timespec_sub): Fix off-by-2 bug if a.tv_sec == TYPE_MINIMUM (time_t) and 0 < b.tv_sec. * modules/timespec-tests, tests/test-timespec.c: New files. |