From b47a223bfb2c7114154504ec8d6cdac5abd0b884 Mon Sep 17 00:00:00 2001 From: Garrett D'Amore Date: Mon, 14 Aug 2017 21:58:02 -0700 Subject: Convert duration to usec. --- src/protocol/reqrep/req.c | 4 ++-- src/protocol/survey/survey.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'src/protocol') diff --git a/src/protocol/reqrep/req.c b/src/protocol/reqrep/req.c index 20fb07f8..fdf29fd9 100644 --- a/src/protocol/reqrep/req.c +++ b/src/protocol/reqrep/req.c @@ -273,7 +273,7 @@ nni_req_sock_setopt(void *arg, int opt, const void *buf, size_t sz) switch (opt) { case NNG_OPT_RESENDTIME: - rv = nni_setopt_duration(&req->retry, buf, sz); + rv = nni_setopt_usec(&req->retry, buf, sz); break; case NNG_OPT_RAW: rv = nni_setopt_int(&req->raw, buf, sz, 0, 1); @@ -298,7 +298,7 @@ nni_req_sock_getopt(void *arg, int opt, void *buf, size_t *szp) switch (opt) { case NNG_OPT_RESENDTIME: - rv = nni_getopt_duration(&req->retry, buf, szp); + rv = nni_getopt_usec(&req->retry, buf, szp); break; case NNG_OPT_RAW: rv = nni_getopt_int(&req->raw, buf, szp); diff --git a/src/protocol/survey/survey.c b/src/protocol/survey/survey.c index 45b06d67..cb90c13f 100644 --- a/src/protocol/survey/survey.c +++ b/src/protocol/survey/survey.c @@ -295,7 +295,7 @@ nni_surv_sock_setopt(void *arg, int opt, const void *buf, size_t sz) switch (opt) { case NNG_OPT_SURVEYTIME: - rv = nni_setopt_duration(&psock->survtime, buf, sz); + rv = nni_setopt_usec(&psock->survtime, buf, sz); break; case NNG_OPT_RAW: oldraw = psock->raw; @@ -324,7 +324,7 @@ nni_surv_sock_getopt(void *arg, int opt, void *buf, size_t *szp) switch (opt) { case NNG_OPT_SURVEYTIME: - rv = nni_getopt_duration(&psock->survtime, buf, szp); + rv = nni_getopt_usec(&psock->survtime, buf, szp); break; case NNG_OPT_RAW: rv = nni_getopt_int(&psock->raw, buf, szp); -- cgit v1.2.3-70-g09d2