diff options
author | Damien Miller <djm@cvs.openbsd.org> | 2011-04-12 04:23:51 +0000 |
---|---|---|
committer | Damien Miller <djm@cvs.openbsd.org> | 2011-04-12 04:23:51 +0000 |
commit | 2184ceb20ca2196c15e8ab328ce8c02bc6a22ba4 (patch) | |
tree | b109f2902f97a6e35551ec53937ae263c7b10697 /usr.bin/ssh | |
parent | c3f71edc9a20f8d977df10d6a653b5ed0dd26ce4 (diff) |
fix -Wshadow
Diffstat (limited to 'usr.bin/ssh')
-rw-r--r-- | usr.bin/ssh/ssh-keygen.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/usr.bin/ssh/ssh-keygen.c b/usr.bin/ssh/ssh-keygen.c index d94dffe936c..c72c5c0d792 100644 --- a/usr.bin/ssh/ssh-keygen.c +++ b/usr.bin/ssh/ssh-keygen.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ssh-keygen.c,v 1.208 2011/03/24 22:14:54 stevesk Exp $ */ +/* $OpenBSD: ssh-keygen.c,v 1.209 2011/04/12 04:23:50 djm Exp $ */ /* * Author: Tatu Ylonen <ylo@cs.hut.fi> * Copyright (c) 1994 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland @@ -152,7 +152,7 @@ int gen_candidates(FILE *, u_int32_t, u_int32_t, BIGNUM *); int prime_test(FILE *, FILE *, u_int32_t, u_int32_t); static void -type_bits_valid(int type, u_int32_t *bits) +type_bits_valid(int type, u_int32_t *bitsp) { u_int maxbits; @@ -160,25 +160,25 @@ type_bits_valid(int type, u_int32_t *bits) fprintf(stderr, "unknown key type %s\n", key_type_name); exit(1); } - if (*bits == 0) { + if (*bitsp == 0) { if (type == KEY_DSA) - *bits = DEFAULT_BITS_DSA; + *bitsp = DEFAULT_BITS_DSA; else if (type == KEY_ECDSA) - *bits = DEFAULT_BITS_ECDSA; + *bitsp = DEFAULT_BITS_ECDSA; else - *bits = DEFAULT_BITS; + *bitsp = DEFAULT_BITS; } maxbits = (type == KEY_DSA) ? OPENSSL_DSA_MAX_MODULUS_BITS : OPENSSL_RSA_MAX_MODULUS_BITS; - if (*bits > maxbits) { + if (*bitsp > maxbits) { fprintf(stderr, "key bits exceeds maximum %d\n", maxbits); exit(1); } - if (type == KEY_DSA && *bits != 1024) + if (type == KEY_DSA && *bitsp != 1024) fatal("DSA keys must be 1024 bits"); - else if (type != KEY_ECDSA && *bits < 768) + else if (type != KEY_ECDSA && *bitsp < 768) fatal("Key must at least be 768 bits"); - else if (type == KEY_ECDSA && key_ecdsa_bits_to_nid(*bits) == -1) + else if (type == KEY_ECDSA && key_ecdsa_bits_to_nid(*bitsp) == -1) fatal("Invalid ECDSA key length - valid lengths are " "256, 384 or 521 bits"); } |