summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2015-01-04 02:28:26 +0000
committerderaadt <deraadt@openbsd.org>2015-01-04 02:28:26 +0000
commit260df0be86c6adefbd0e495fbc73fcd8f40ee2fa (patch)
tree00c917bf559d44817d3357dcbbb728e14b39253b
parentgo back to using /mnt encrypt. it seems something isn't working yet. (diff)
downloadwireguard-openbsd-260df0be86c6adefbd0e495fbc73fcd8f40ee2fa.tar.xz
wireguard-openbsd-260df0be86c6adefbd0e495fbc73fcd8f40ee2fa.zip
fix -b a mode, spotted by rpe
-rw-r--r--usr.bin/encrypt/encrypt.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/usr.bin/encrypt/encrypt.c b/usr.bin/encrypt/encrypt.c
index 074fcec94cb..bffd604a4a4 100644
--- a/usr.bin/encrypt/encrypt.c
+++ b/usr.bin/encrypt/encrypt.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: encrypt.c,v 1.35 2014/12/29 17:07:17 tedu Exp $ */
+/* $OpenBSD: encrypt.c,v 1.36 2015/01/04 02:28:26 deraadt Exp $ */
/*
* Copyright (c) 1996, Jason Downs. All rights reserved.
@@ -141,10 +141,11 @@ main(int argc, char **argv)
operation = DO_BLF;
if (strcmp(optarg, "a") == 0)
rounds = ideal_rounds();
- else
+ else {
rounds = strtonum(optarg, 1, INT_MAX, &errstr);
- if (errstr != NULL)
- errx(1, "%s: %s", errstr, optarg);
+ if (errstr != NULL)
+ errx(1, "%s: %s", errstr, optarg);
+ }
extra = &rounds;
break;
case 'c': /* user login class */