From: Richard Levitte Date: Tue, 25 Aug 2009 10:13:56 +0000 (+0000) Subject: Correct various typos X-Git-Tag: yubikey-personalisation_1.3.5-1~4^2~95 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f19c41897927f1c191509a2347e4226d1c2f6a7c;p=yubikey-personalization Correct various typos --- diff --git a/ykpersonalize.c b/ykpersonalize.c index 9bd81dd..e46358e 100644 --- a/ykpersonalize.c +++ b/ykpersonalize.c @@ -176,17 +176,17 @@ main(int argc, char **argv) else printf("Unconfigured\n"); - if (ykp_configure_for(cfg, 1, st)) + if (!ykp_configure_for(cfg, 1, st)) goto err; while((c = getopt(argc, argv, optstring)) != -1) { switch (c) { case '1': - if (ykp_configure_for(cfg, 1, st)) + if (!ykp_configure_for(cfg, 1, st)) goto err; break; case '2': - if (ykp_configure_for(cfg, 2, st)) + if (!ykp_configure_for(cfg, 2, st)) goto err; break; case 'i': @@ -399,7 +399,7 @@ main(int argc, char **argv) fgets(passphrasebuf, sizeof(passphrasebuf), stdin); passphraselen = strlen(passphrasebuf); if (passphrasebuf[passphraselen - 1] == '\n') - passphrasebuf[passphraselen - 1] == '\0'; + passphrasebuf[passphraselen - 1] = '\0'; if (!ykp_AES_key_from_passphrase(cfg, passphrasebuf, salt)) goto err; @@ -422,7 +422,7 @@ main(int argc, char **argv) } commitlen = strlen(commitbuf); if (commitbuf[commitlen - 1] == '\n') - commitbuf[commitlen - 1] == '\0'; + commitbuf[commitlen - 1] = '\0'; if (strcmp(commitbuf, "y") == 0 || strcmp(commitbuf, "yes") == 0) { exit_code = 2;