diff options
author | Martin Willi <martin@revosec.ch> | 2012-07-06 10:58:19 +0200 |
---|---|---|
committer | Martin Willi <martin@revosec.ch> | 2012-07-16 14:53:34 +0200 |
commit | bb1e0c59e1e2195d46542ca9e9194486b913a0dd (patch) | |
tree | 7c33a3347b8c236deae8f467f5895469695526a9 /src/conftest/hooks/pretend_auth.c | |
parent | 2baae8e3ea121a706b911f9dad3f1078ccf4905f (diff) | |
download | strongswan-bb1e0c59e1e2195d46542ca9e9194486b913a0dd.tar.bz2 strongswan-bb1e0c59e1e2195d46542ca9e9194486b913a0dd.tar.xz |
Add a return value to keymat_v2_t.get_auth_octets()
Diffstat (limited to 'src/conftest/hooks/pretend_auth.c')
-rw-r--r-- | src/conftest/hooks/pretend_auth.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/conftest/hooks/pretend_auth.c b/src/conftest/hooks/pretend_auth.c index cfc39e3a9..4166afc79 100644 --- a/src/conftest/hooks/pretend_auth.c +++ b/src/conftest/hooks/pretend_auth.c @@ -237,8 +237,12 @@ static bool build_auth(private_pretend_auth_t *this, return FALSE; } keymat = (keymat_v2_t*)ike_sa->get_keymat(ike_sa); - octets = keymat->get_auth_octets(keymat, TRUE, this->ike_init, - this->nonce, this->id, this->reserved); + if (!keymat->get_auth_octets(keymat, TRUE, this->ike_init, + this->nonce, this->id, this->reserved, &octets)) + { + private->destroy(private); + return FALSE; + } if (!private->sign(private, scheme, octets, &auth_data)) { chunk_free(&octets); |