From 258fc6e84ec0d8b5597c1b0ba1f37d8b20a01297 Mon Sep 17 00:00:00 2001 From: "Suren A. Chilingaryan" Date: Mon, 12 Dec 2011 18:17:47 +0100 Subject: Fix errors preventing time-limited grabbing --- tools.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tools.c') diff --git a/tools.c b/tools.c index 4105597..e0789fb 100644 --- a/tools.c +++ b/tools.c @@ -347,7 +347,7 @@ pcilib_timeout_t pcilib_timediff(struct timeval *tvs, struct timeval *tve) { int pcilib_timecmp(struct timeval *tv1, struct timeval *tv2) { if (tv1->tv_sec > tv2->tv_sec) return 1; - else if (tv1->tv_sec > tv2->tv_sec) return -1; + else if (tv1->tv_sec < tv2->tv_sec) return -1; else if (tv1->tv_usec > tv2->tv_usec) return 1; else if (tv1->tv_usec < tv2->tv_usec) return -1; return 0; -- cgit v1.2.3