Add a return value to crypter_t.set_key()

This commit is contained in:
Martin Willi
2012-07-16 14:53:38 +02:00
parent 3b96189a2a
commit ce73fc19db
23 changed files with 87 additions and 57 deletions
+2 -2
View File
@@ -348,8 +348,8 @@ METHOD(aead_t, set_key, bool,
{
memcpy(this->salt, key.ptr + key.len - SALT_SIZE, SALT_SIZE);
key.len -= SALT_SIZE;
this->crypter->set_key(this->crypter, key);
return create_h(this, this->h);
return this->crypter->set_key(this->crypter, key) &&
create_h(this, this->h);
}
METHOD(aead_t, destroy, void,