Oct. 10, 1998
6:32 p.m.
Paul Eggert writes:
The same as 1 month before 31 March.
Okay. You can easily implement that on top of something like mktime(): void month_add(struct caldate *out,struct caldate *in,int m) { *out = *in; out->month += m; normalize(out); if (out->day != in->day) { out->day = FIRST - 1; normalize(out); } } This example certainly doesn't convince me that mktime()'s handling of invalid dates is a bad thing. ---Dan 1000 recipients, 28.8 modem, 10 seconds. http://pobox.com/~djb/qmail/mini.html