Commit 53a54099 by Serge Hallyn

attach: free result before potentially strduping a second time.

parent cb3e61fa
......@@ -355,6 +355,8 @@ char *lxc_attach_getpwshell(uid_t uid)
}
if (!token)
continue;
if (result)
free(result);
result = strdup(token);
/* sanity check that there are no fields after that */
......
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