]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
confile: cleanup get_config_sysctl()
authorChristian Brauner <christian.brauner@ubuntu.com>
Tue, 8 Dec 2020 16:20:03 +0000 (17:20 +0100)
committerChristian Brauner <christian.brauner@ubuntu.com>
Tue, 8 Dec 2020 16:20:03 +0000 (17:20 +0100)
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/lxc/confile.c

index 883c744484e3de39da014946545b40f756234175..2166d7e7fc7be7eee2b4448491196f9b3fb36698 100644 (file)
@@ -4363,7 +4363,7 @@ static int get_config_sysctl(const char *key, char *retv, int inlen,
        else if (strncmp(key, "lxc.sysctl.", STRLITERALLEN("lxc.sysctl.")) == 0)
                key += STRLITERALLEN("lxc.sysctl.");
        else
-               return -1;
+               return ret_errno(EINVAL);
 
        lxc_list_for_each(it, &c->sysctls) {
                struct lxc_sysctl *elem = it->elem;