cron2 has uploaded a new patch set (#2) to the change originally created by flichtenheld. ( http://gerrit.openvpn.net/c/openvpn/+/1356?usp=email )
The following approvals got outdated and were removed: Code-Review+2 by plaisthos Change subject: forward: Change context_reschedule_sec sec argument to time_t ...................................................................... forward: Change context_reschedule_sec sec argument to time_t This avoids conversions at the caller sites. Since we only replace tv_sec if the new value is smaller the cast to tv_sec_t is also safe. Change-Id: Id9158f477404aac1d6b08b08e672980e5a58dc35 Signed-off-by: Frank Lichtenheld <[email protected]> Acked-by: Arne Schwabe <[email protected]> Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1356 Message-Id: <[email protected]> URL: https://www.mail-archive.com/[email protected]/msg34319.html Signed-off-by: Gert Doering <[email protected]> --- M src/openvpn/forward.c 1 file changed, 8 insertions(+), 7 deletions(-) git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/56/1356/2 diff --git a/src/openvpn/forward.c b/src/openvpn/forward.c index 90e52d2..f01fb4c 100644 --- a/src/openvpn/forward.c +++ b/src/openvpn/forward.c @@ -33,6 +33,7 @@ #include "mss.h" #include "event.h" #include "occ.h" +#include "otime.h" #include "ping.h" #include "ps.h" #include "dhcp.h" @@ -127,7 +128,7 @@ } static inline void -context_reschedule_sec(struct context *c, int sec) +context_reschedule_sec(struct context *c, time_t sec) { if (sec < 0) { @@ -135,7 +136,7 @@ } if (sec < c->c2.timeval.tv_sec) { - c->c2.timeval.tv_sec = sec; + c->c2.timeval.tv_sec = (tv_sec_t)sec; c->c2.timeval.tv_usec = 0; } } @@ -829,11 +830,6 @@ #endif /* ENABLE_MANAGEMENT */ } -#if defined(__GNUC__) || defined(__clang__) -#pragma GCC diagnostic push -#pragma GCC diagnostic ignored "-Wconversion" -#endif - static void check_coarse_timers(struct context *c) { @@ -1304,6 +1300,11 @@ #endif /* if defined(ENABLE_DCO) && (defined(TARGET_LINUX) || defined(TARGET_FREEBSD)) */ } +#if defined(__GNUC__) || defined(__clang__) +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wconversion" +#endif + /* * Output: c->c2.buf */ -- To view, visit http://gerrit.openvpn.net/c/openvpn/+/1356?usp=email To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email Gerrit-MessageType: newpatchset Gerrit-Project: openvpn Gerrit-Branch: master Gerrit-Change-Id: Id9158f477404aac1d6b08b08e672980e5a58dc35 Gerrit-Change-Number: 1356 Gerrit-PatchSet: 2 Gerrit-Owner: flichtenheld <[email protected]> Gerrit-Reviewer: plaisthos <[email protected]> Gerrit-CC: openvpn-devel <[email protected]>
_______________________________________________ Openvpn-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/openvpn-devel
