summaryrefslogtreecommitdiff
path: root/lib/timeval.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2004-04-06 10:15:10 +0000
committerDaniel Stenberg <daniel@haxx.se>2004-04-06 10:15:10 +0000
commit780b962336cfe614406b0e56fde3f0a130693d6c (patch)
tree10138d1a2e812dcd3dea6f956b8e21b8a8404624 /lib/timeval.c
parentbbeb840916c446a605d3c4645800b6add1f32b77 (diff)
downloadcurl-780b962336cfe614406b0e56fde3f0a130693d6c.tar.gz
provide these functions as curlx_* ones as this enables the curl app to
re-use these sources and functions for subsecond resolution timing
Diffstat (limited to 'lib/timeval.c')
-rw-r--r--lib/timeval.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/timeval.c b/lib/timeval.c
index b9bd1f994..20ac6ea96 100644
--- a/lib/timeval.c
+++ b/lib/timeval.c
@@ -79,7 +79,7 @@ static int gettimeofday(struct timeval *tp, void *nothing)
#endif /* HAVE_GETTIMEOFDAY */
/* Return the current time in a timeval struct */
-struct timeval Curl_tvnow(void)
+struct timeval curlx_tvnow(void)
{
struct timeval now;
(void)gettimeofday(&now, NULL);
@@ -92,10 +92,10 @@ struct timeval Curl_tvnow(void)
*
* Returns: the time difference in number of milliseconds.
*/
-long Curl_tvdiff(struct timeval newer, struct timeval older)
+long curlx_tvdiff(struct timeval newer, struct timeval older)
{
return (newer.tv_sec-older.tv_sec)*1000+
- (499+newer.tv_usec-older.tv_usec)/1000;
+ (newer.tv_usec-older.tv_usec)/1000;
}
/* return the number of seconds in the given input timeval struct */