From 5b64c697eaa5ee5e97c8c45a077ca4545ebdbfa3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adrien=20Gallou=C3=ABt?= Date: Sat, 1 Dec 2018 14:56:03 +0000 Subject: [PATCH] Remove option timeout MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Adrien Gallouët --- src/bind.c | 4 ---- src/ctl.h | 1 - src/set.c | 22 ---------------------- 3 files changed, 27 deletions(-) diff --git a/src/bind.c b/src/bind.c index fef5786..da7e78b 100644 --- a/src/bind.c +++ b/src/bind.c @@ -290,10 +290,6 @@ gt_bind(int argc, char **argv) if (mud_set_keyx_timeout(mud, req.ms)) res.ret = errno; break; - case CTL_TIMEOUT: - if (mud_set_send_timeout(mud, req.ms)) - res.ret = errno; - break; case CTL_TIMETOLERANCE: if (mud_set_time_tolerance(mud, req.ms)) res.ret = errno; diff --git a/src/ctl.h b/src/ctl.h index e1fa658..5688241 100644 --- a/src/ctl.h +++ b/src/ctl.h @@ -11,7 +11,6 @@ enum ctl_type { CTL_MTU, CTL_TC, CTL_KXTIMEOUT, - CTL_TIMEOUT, CTL_TIMETOLERANCE, CTL_PATH_STATUS, CTL_SYNC, diff --git a/src/set.c b/src/set.c index e7ef5cd..73ee06f 100644 --- a/src/set.c +++ b/src/set.c @@ -45,24 +45,6 @@ gt_set_kxtimeout(int fd, unsigned long ms) return 0; } -static int -gt_set_timeout(int fd, unsigned long ms) -{ - struct ctl_msg res, req = { - .type = CTL_TIMEOUT, - .ms = ms, - }; - - int ret = ctl_reply(fd, &res, &req); - - if (ret) { - perror("set timeout"); - return 1; - } - - return 0; -} - static int gt_set_timetolerance(int fd, unsigned long ms) { @@ -140,7 +122,6 @@ gt_set(int argc, char **argv) {"mtu", "BYTES", &mtu, argz_bytes}, {"tc", "CS|AF|EF", &tc, gt_argz_tc}, {"kxtimeout", "SECONDS", &kxtimeout, argz_time}, - {"timeout", "SECONDS", &timeout, argz_time}, {"timetolerance", "SECONDS", &timetolerance, argz_time}, {NULL}}; @@ -177,9 +158,6 @@ gt_set(int argc, char **argv) if (argz_is_set(pathz, "kxtimeout")) ret |= gt_set_kxtimeout(fd, kxtimeout); - if (argz_is_set(pathz, "timeout")) - ret |= gt_set_timeout(fd, timeout); - if (argz_is_set(pathz, "timetolerance")) ret |= gt_set_timetolerance(fd, timetolerance);