diff options
| author | Garrett D'Amore <garrett@damore.org> | 2017-10-19 15:16:25 -0700 |
|---|---|---|
| committer | Garrett D'Amore <garrett@damore.org> | 2017-10-19 17:56:49 -0700 |
| commit | 4e668fdd5b5da0d46f97d835249dbe5f0ea319a7 (patch) | |
| tree | 0aaad8a672024b3a510763150b167320be6f1f5b /src/platform/posix/posix_thread.c | |
| parent | d7e39a2423212a31c5ef62dcb0b7a5b4bf9f34df (diff) | |
| download | nng-4e668fdd5b5da0d46f97d835249dbe5f0ea319a7.tar.gz nng-4e668fdd5b5da0d46f97d835249dbe5f0ea319a7.tar.bz2 nng-4e668fdd5b5da0d46f97d835249dbe5f0ea319a7.zip | |
fixes #84 Consider using msec for durations
There is now a public nng_duration type. We have also updated the
zerotier work to work with the signed int64_t's that the latst ZeroTier
dev branch is using.
Diffstat (limited to 'src/platform/posix/posix_thread.c')
| -rw-r--r-- | src/platform/posix/posix_thread.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/platform/posix/posix_thread.c b/src/platform/posix/posix_thread.c index 4278a057..115768dc 100644 --- a/src/platform/posix/posix_thread.c +++ b/src/platform/posix/posix_thread.c @@ -354,8 +354,8 @@ nni_plat_cv_until(nni_plat_cv *cv, nni_time until) NNI_ASSERT(cv->mtx->owner == pthread_self()); // Our caller has already guaranteed a sane value for until. - ts.tv_sec = until / 1000000; - ts.tv_nsec = (until % 1000000) * 1000; + ts.tv_sec = until / 1000; + ts.tv_nsec = (until % 1000) * 1000000; if (cv->fallback) { rv = nni_plat_cv_until_fallback(cv, &ts); |
