]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
Fix ktime test for errors
authorRuss Allbery <rra@stanford.edu>
Sat, 10 Jul 2010 01:06:47 +0000 (18:06 -0700)
committerDerrick Brashear <shadow@dementia.org>
Sat, 10 Jul 2010 13:35:53 +0000 (06:35 -0700)
The variable passed into ktime_DateToLong must be initialized to 0
or, on error, we get the previous value and the tests fail.

Change-Id: I5528a830981a85fb6737bb8cb5931ab95faffb13
Reviewed-on: http://gerrit.openafs.org/2379
Tested-by: Russ Allbery <rra@stanford.edu>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
tests/util/ktime-t.c

index 7b6297b6d8c9a6dc34ff9c211df995f1d834734f..568cd3a052969df372fe000e0f598747b9eaf855 100644 (file)
@@ -78,7 +78,7 @@ main(void)
 
     errors = 0;
     for (tt = testTimes; tt->time; tt++) {
-        t = 0;
+       temp = 0;
        code = ktime_DateToLong(tt->time, &temp);
        t = temp;
         if (tt->code == 1) {