summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJosé Fonseca <[email protected]>2008-04-15 15:40:35 +0900
committerJosé Fonseca <[email protected]>2008-04-15 15:40:35 +0900
commitd005befcb9e191ae90619fbdd3c37e262ae3b03e (patch)
treee7ddc28306ea8ad14123ffbf764f94930d9e7bf7 /src
parent50bbbbe581edd6b8d4fe9f8ba7f134e17dc80a0b (diff)
gallium: Less confusing interface for timeouts.
Diffstat (limited to 'src')
-rw-r--r--src/gallium/auxiliary/util/u_time.c6
-rw-r--r--src/gallium/auxiliary/util/u_time.h4
2 files changed, 5 insertions, 5 deletions
diff --git a/src/gallium/auxiliary/util/u_time.c b/src/gallium/auxiliary/util/u_time.c
index 04f85c42efb..01112ebe5aa 100644
--- a/src/gallium/auxiliary/util/u_time.c
+++ b/src/gallium/auxiliary/util/u_time.c
@@ -120,15 +120,15 @@ util_time_compare(const struct util_time *t1,
}
-int
+boolean
util_time_timeout(const struct util_time *start,
const struct util_time *end,
const struct util_time *curr)
{
if(util_time_compare(start, end) <= 0)
- return util_time_compare(start, curr) <= 0 && util_time_compare(curr, end) < 0;
+ return !(util_time_compare(start, curr) <= 0 && util_time_compare(curr, end) < 0);
else
- return util_time_compare(start, curr) <= 0 || util_time_compare(curr, end) < 0;
+ return !(util_time_compare(start, curr) <= 0 || util_time_compare(curr, end) < 0);
}
diff --git a/src/gallium/auxiliary/util/u_time.h b/src/gallium/auxiliary/util/u_time.h
index 2133958446b..c8836c137fa 100644
--- a/src/gallium/auxiliary/util/u_time.h
+++ b/src/gallium/auxiliary/util/u_time.h
@@ -77,9 +77,9 @@ util_time_diff(const struct util_time *t1,
const struct util_time *t2);
/**
- * Returns zero when the timeout expires, non zero otherwise.
+ * Returns non-zero when the timeout expires.
*/
-int
+boolean
util_time_timeout(const struct util_time *start,
const struct util_time *end,
const struct util_time *curr);