diff options
author | Martin Willi <martin@revosec.ch> | 2012-07-06 15:54:03 +0200 |
---|---|---|
committer | Martin Willi <martin@revosec.ch> | 2012-07-16 14:53:37 +0200 |
commit | e35abbe588636c5ca73d8aaa9082314289346bd9 (patch) | |
tree | eece22634e08ca1ada844d640bb8d8c2d086e61a /scripts/crypt_burn.c | |
parent | c3858662d2d1d431bdb453f2b50e63d9c2c5bfad (diff) | |
download | strongswan-e35abbe588636c5ca73d8aaa9082314289346bd9.tar.bz2 strongswan-e35abbe588636c5ca73d8aaa9082314289346bd9.tar.xz |
Add a return value to crypter_t.encrypt
Diffstat (limited to 'scripts/crypt_burn.c')
-rw-r--r-- | scripts/crypt_burn.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/scripts/crypt_burn.c b/scripts/crypt_burn.c index 3b05144e8..64eb162c9 100644 --- a/scripts/crypt_burn.c +++ b/scripts/crypt_burn.c @@ -104,9 +104,12 @@ int main(int argc, char *argv[]) while (i--) { - crypter->encrypt(crypter, - chunk_create(buffer, sizeof(buffer) / bs * bs), - chunk_create(iv, crypter->get_iv_size(crypter)), NULL); + if (!crypter->encrypt(crypter, + chunk_create(buffer, sizeof(buffer) / bs * bs), + chunk_create(iv, crypter->get_iv_size(crypter)), NULL)) + { + continue; + } crypter->decrypt(crypter, chunk_create(buffer, sizeof(buffer) / bs * bs), chunk_create(iv, crypter->get_iv_size(crypter)), NULL); |