coverity: #1440391

Dereference null return value Signed-off-by: 's avatarChristian Brauner <christian.brauner@ubuntu.com>
parent e62f1fe8
......@@ -3272,8 +3272,10 @@ static int get_config_hooks(const char *key, char *retv, int inlen,
return -1;
subkey = strchr(subkey + 1, '.');
if (!subkey)
return -1;
subkey++;
if (!*subkey)
if (*subkey == '\0')
return -1;
for (i = 0; i < NUM_LXC_HOOKS; i++) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment