]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
lxc-monitord: fix integer comparisions
authorChristian Brauner <christian.brauner@ubuntu.com>
Thu, 14 Oct 2021 15:34:25 +0000 (17:34 +0200)
committerChristian Brauner <christian.brauner@ubuntu.com>
Thu, 14 Oct 2021 15:34:25 +0000 (17:34 +0200)
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/lxc/cmd/lxc_monitord.c

index d505991c71d092bb95bbc6fda2be4a47cc01a71d..2b0895fc6ecd72a5538fea848dba0b0fac5a90fd 100644 (file)
@@ -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;