DPP: Fix uninitialised variable on error path
The current code generates a warning when compiled by Clang, because if we goto 'fail:', password_len can be uninitialised when we pass it in to bin_clear_free(). Note that the actual usage is safe, because bin_clear_free() ignores the second argument if the first argument is NULL, but it still seems worth cleaning up. Signed-off-by: Alasdair Mackintosh <alasdair at google.com>
This commit is contained in:
parent
3a157fe92f
commit
ae512c30a1
1 changed files with 1 additions and 1 deletions
|
@ -2059,7 +2059,7 @@ struct wpabuf * dpp_build_csr(struct dpp_authentication *auth, const char *name)
|
|||
struct wpabuf *priv_key;
|
||||
u8 cp[DPP_CP_LEN];
|
||||
char *password = NULL;
|
||||
size_t password_len;
|
||||
size_t password_len = 0;
|
||||
int hash_sign_algo;
|
||||
|
||||
/* TODO: use auth->csrattrs */
|
||||
|
|
Loading…
Add table
Reference in a new issue