diffie-hellman: Use bool instead of status_t as get_shared_secret() return value
While such a change is not unproblematic, keeping status_t makes the API inconsistent once we introduce return values for the public value operations.
This commit is contained in:
@@ -495,7 +495,7 @@ static status_t process_key_exchange_dhe(private_tls_server_t *this,
|
||||
pub = chunk_skip(pub, 1);
|
||||
}
|
||||
this->dh->set_other_public_value(this->dh, pub);
|
||||
if (this->dh->get_shared_secret(this->dh, &premaster) != SUCCESS)
|
||||
if (!this->dh->get_shared_secret(this->dh, &premaster))
|
||||
{
|
||||
DBG1(DBG_TLS, "calculating premaster from DH failed");
|
||||
this->alert->add(this->alert, TLS_FATAL, TLS_INTERNAL_ERROR);
|
||||
|
||||
Reference in New Issue
Block a user