From: Christian Brauner Date: Thu, 14 Oct 2021 15:34:25 +0000 (+0200) Subject: lxc-monitord: fix integer comparisions X-Git-Tag: lxc-4.0.11~11 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ca9340977220ede76f8d41d4638cf9568f2b71a2;p=thirdparty%2Flxc.git lxc-monitord: fix integer comparisions Signed-off-by: Christian Brauner --- diff --git a/src/lxc/cmd/lxc_monitord.c b/src/lxc/cmd/lxc_monitord.c index d505991c7..2b0895fc6 100644 --- a/src/lxc/cmd/lxc_monitord.c +++ b/src/lxc/cmd/lxc_monitord.c @@ -345,7 +345,7 @@ int main(int argc, char *argv[]) ret = snprintf(logpath, sizeof(logpath), "%s/lxc-monitord.log", (strcmp(LXCPATH, lxcpath) ? lxcpath : LOGPATH)); - if (ret < 0 || ret >= sizeof(logpath)) + if (ret < 0 || (size_t)ret >= sizeof(logpath)) exit(EXIT_FAILURE); log.name = NULL;