diff options
author | Ted Unangst <tedu@cvs.openbsd.org> | 2015-12-04 11:05:23 +0000 |
---|---|---|
committer | Ted Unangst <tedu@cvs.openbsd.org> | 2015-12-04 11:05:23 +0000 |
commit | a4ce54f07022f1ff27ad7ee8e1be5996c5eddf00 (patch) | |
tree | faaa8240684b464329e5911a4527c370996c7850 /usr.bin/signify | |
parent | 44979e2835b79addd34f3961c0857e2a9a830018 (diff) |
polishing
Diffstat (limited to 'usr.bin/signify')
-rw-r--r-- | usr.bin/signify/signify.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/usr.bin/signify/signify.c b/usr.bin/signify/signify.c index 3bc4c6c9951..a4cb84ae9ea 100644 --- a/usr.bin/signify/signify.c +++ b/usr.bin/signify/signify.c @@ -1,4 +1,4 @@ -/* $OpenBSD: signify.c,v 1.104 2015/11/02 22:01:10 bluhm Exp $ */ +/* $OpenBSD: signify.c,v 1.105 2015/12/04 11:05:22 tedu Exp $ */ /* * Copyright (c) 2013 Ted Unangst <tedu@openbsd.org> * @@ -367,7 +367,7 @@ sign(const char *seckeyfile, const char *msgfile, const char *sigfile, SHA512Update(&ctx, enckey.seckey, sizeof(enckey.seckey)); SHA512Final(digest, &ctx); if (memcmp(enckey.checksum, digest, sizeof(enckey.checksum)) != 0) - errx(1, "incorrect passphrase"); + errx(1, "incorrect passphrase"); explicit_bzero(digest, sizeof(digest)); msg = readmsg(msgfile, &msglen); @@ -559,9 +559,8 @@ verifychecksum(struct checksum *c, int quiet) } else { errx(1, "can't handle algorithm %s", c->algo); } - if (strcmp(c->hash, buf) != 0) { + if (strcmp(c->hash, buf) != 0) return 0; - } if (!quiet) printf("%s: OK\n", c->file); return 1; |