aboutsummaryrefslogtreecommitdiffstats
path: root/src/cli
diff options
context:
space:
mode:
authorJack Lloyd <[email protected]>2016-10-30 13:29:58 -0400
committerJack Lloyd <[email protected]>2016-10-30 13:29:58 -0400
commit67990086f7bcefee9b5376fe4d98ff11a6614807 (patch)
treedfb30596acb7ce785a1d4831fc3acea238b8f852 /src/cli
parentb7637f3b74a6b0727c99a9855e5f6dc01e218952 (diff)
Fix crash when default IV is empty. GH #697
Diffstat (limited to 'src/cli')
-rw-r--r--src/cli/speed.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/cli/speed.cpp b/src/cli/speed.cpp
index 0cb5e9947..923abe5c2 100644
--- a/src/cli/speed.cpp
+++ b/src/cli/speed.cpp
@@ -590,7 +590,8 @@ class Speed final : public Command
iv_timer.run([&] { dec.start(iv); });
decrypt_timer.run([&] { dec.finish(buffer); });
- iv[0] += 1;
+ if(iv.size() > 0)
+ iv[0] += 1;
}
output() << Timer::result_string_ops(ks_timer);