time: test/run-monotonic backwards timemono_between fix.
authorRusty Russell <rusty@rustcorp.com.au>
Mon, 31 Oct 2016 00:30:57 +0000 (11:00 +1030)
committerRusty Russell <rusty@rustcorp.com.au>
Mon, 31 Oct 2016 00:30:57 +0000 (11:00 +1030)
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
ccan/time/test/run-monotonic.c

index c9912a73a608a0fcc7b1c92d5b44d95e067b2652..2da492d441b0160731ce4f431d31031c9b7e67a3 100644 (file)
@@ -18,7 +18,7 @@ int main(void)
        t3.ts.tv_sec = 1;
        t3.ts.tv_nsec = 0;
 
-       ok1(time_less(timemono_between(t1, t2), t3));
+       ok1(time_less(timemono_between(t2, t1), t3));
        ok1(time_less(timemono_since(t1), t3));
 
        ok1(timemono_add(t1, t3).ts.tv_sec == t1.ts.tv_sec + 1);