If cifs.upcall is passed an invalid argument then it will "goto out".
The decoded_args struct however is uninitialized at that point so it
will usually segfault when trying to free fields in it. Move the
initialization up in the function.
Signed-off-by: Jeff Layton <jlayton@samba.org>
const char *oid;
hostbuf[0] = '\0';
+ memset(&arg, 0, sizeof(arg));
openlog(prog, 0, LOG_DAEMON);
goto out;
}
- memset(&arg, 0, sizeof(arg));
-
have = decode_key_description(buf, &arg);
SAFE_FREE(buf);
if ((have & DKD_MUSTHAVE_SET) != DKD_MUSTHAVE_SET) {