Unchecked malloc fixes
Miscellaneous unchecked malloc fixes. Also fixed some mem leaks on error paths as I spotted them along the way. Reviewed-by: Tim Hudson <tjh@openssl.org>
This commit is contained in:
@@ -550,6 +550,11 @@ static char *ssl_give_srp_client_pwd_cb(SSL *s, void *arg)
|
||||
PW_CB_DATA cb_tmp;
|
||||
int l;
|
||||
|
||||
if(!pass) {
|
||||
BIO_printf(bio_err, "Malloc failure\n");
|
||||
return NULL;
|
||||
}
|
||||
|
||||
cb_tmp.password = (char *)srp_arg->srppassin;
|
||||
cb_tmp.prompt_info = "SRP user";
|
||||
if ((l = password_callback(pass, PWD_STRLEN, 0, &cb_tmp)) < 0) {
|
||||
|
||||
Reference in New Issue
Block a user