]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
login-common: Fix implicit integer conversions when connect timeout is reached
authorTimo Sirainen <timo.sirainen@open-xchange.com>
Thu, 18 Feb 2021 12:43:06 +0000 (14:43 +0200)
committeraki.tuomi <aki.tuomi@open-xchange.com>
Thu, 25 Feb 2021 12:04:30 +0000 (12:04 +0000)
src/login-common/login-proxy.c

index af38db9fde8b771c56fd510e1d906b4deef7edb1..bb23b90d011aad566d42fdf8603cf9da9339fc24 100644 (file)
@@ -238,7 +238,7 @@ static bool proxy_try_reconnect(struct login_proxy *proxy)
                timeval_diff_msecs(&ioloop_timeval, &proxy->created);
        if (since_started_msecs < 0)
                return FALSE; /* time moved backwards */
-       left_msecs = proxy->connect_timeout_msecs - since_started_msecs;
+       left_msecs = (int)proxy->connect_timeout_msecs - since_started_msecs;
        if (left_msecs <= PROXY_CONNECT_RETRY_MIN_MSECS)
                return FALSE;