diff options
author | Nick Mathewson <nickm@torproject.org> | 2013-02-23 23:31:31 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2013-02-23 23:31:31 -0500 |
commit | 5bfa373eeeb2d76879fe8b0ea130724176f54e81 (patch) | |
tree | f3485ceec073bb6ed01a5a167c48096116115d08 /src/common/util.c | |
parent | 365e302f6153a99fc79b7bad8fafa1d61e839e55 (diff) | |
download | tor-5bfa373eeeb2d76879fe8b0ea130724176f54e81.tar.gz tor-5bfa373eeeb2d76879fe8b0ea130724176f54e81.zip |
Remove some totally unused functions
Diffstat (limited to 'src/common/util.c')
-rw-r--r-- | src/common/util.c | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/src/common/util.c b/src/common/util.c index 6a69635594..ed9a1c9383 100644 --- a/src/common/util.c +++ b/src/common/util.c @@ -1253,42 +1253,6 @@ wrap_string(smartlist_t *out, const char *string, size_t width, * Time * ===== */ -/** - * Converts struct timeval to a double value. - * Preserves microsecond precision, but just barely. - * Error is approx +/- 0.1 usec when dealing with epoch values. - */ -double -tv_to_double(const struct timeval *tv) -{ - double conv = tv->tv_sec; - conv += tv->tv_usec/1000000.0; - return conv; -} - -/** - * Converts timeval to milliseconds. - */ -int64_t -tv_to_msec(const struct timeval *tv) -{ - int64_t conv = ((int64_t)tv->tv_sec)*1000L; - /* Round ghetto-style */ - conv += ((int64_t)tv->tv_usec+500)/1000L; - return conv; -} - -/** - * Converts timeval to microseconds. - */ -int64_t -tv_to_usec(const struct timeval *tv) -{ - int64_t conv = ((int64_t)tv->tv_sec)*1000000L; - conv += tv->tv_usec; - return conv; -} - /** Return the number of microseconds elapsed between *start and *end. */ long |