X-Git-Url: https://git.openafs.org/?p=openafs.git;a=blobdiff_plain;f=tests%2Futil%2Fktime-t.c;h=484ba3ab0a166887b076ebfa88770cea26ce7859;hp=7b6297b6d8c9a6dc34ff9c211df995f1d834734f;hb=HEAD;hpb=19869b100cc144422f2e5e845773d92082a32e40 diff --git a/tests/util/ktime-t.c b/tests/util/ktime-t.c index 7b6297b..484ba3a 100644 --- a/tests/util/ktime-t.c +++ b/tests/util/ktime-t.c @@ -19,15 +19,15 @@ #include #include #include -#include +#include static struct testTime { char *time; long code; - long sec; + time_t sec; } testTimes[] = { { "now", 1, 0 }, /* lookup current time */ - { "never", 0, 0xffffffff }, + { "never", 0, (afs_int32) -1 }, { "12/3/89", 0, 628664400 }, { "1/1/1", 0, 978325200 }, { "1/0/80", -2, 0 }, @@ -66,7 +66,6 @@ main(void) { long code; afs_int32 temp; - int errors; time_t t; struct testTime *tt; @@ -74,11 +73,10 @@ main(void) /* should do timezone and daylight savings time correction so this program * work in other than EST */ - putenv("TZ=EST"); + putenv("TZ=EST+5"); - errors = 0; for (tt = testTimes; tt->time; tt++) { - t = 0; + temp = 0; code = ktime_DateToLong(tt->time, &temp); t = temp; if (tt->code == 1) {