From 154dda73a858a5924c2f5684dfec3e377cc3ab5d Mon Sep 17 00:00:00 2001 From: Damien Miller Date: Tue, 22 Jan 2002 23:08:16 +1100 Subject: - markus@cvs.openbsd.org 2001/12/27 18:10:29 [ssh-keygen.c] -t is only needed for key generation (unbreaks -i, -e, etc). --- ChangeLog | 5 ++++- ssh-keygen.c | 10 +++++----- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/ChangeLog b/ChangeLog index a75883387..9f9772468 100644 --- a/ChangeLog +++ b/ChangeLog @@ -32,6 +32,9 @@ - markus@cvs.openbsd.org 2001/12/25 18:53:00 [auth1.c] be more carefull on allocation + - markus@cvs.openbsd.org 2001/12/27 18:10:29 + [ssh-keygen.c] + -t is only needed for key generation (unbreaks -i, -e, etc). 20020121 - (djm) Rework ssh-rand-helper: @@ -7179,4 +7182,4 @@ - Wrote replacements for strlcpy and mkdtemp - Released 1.0pre1 -$Id: ChangeLog,v 1.1731 2002/01/22 12:07:52 djm Exp $ +$Id: ChangeLog,v 1.1732 2002/01/22 12:08:16 djm Exp $ diff --git a/ssh-keygen.c b/ssh-keygen.c index 9e3a12a54..4f976a826 100644 --- a/ssh-keygen.c +++ b/ssh-keygen.c @@ -12,7 +12,7 @@ */ #include "includes.h" -RCSID("$OpenBSD: ssh-keygen.c,v 1.87 2001/12/21 08:52:22 djm Exp $"); +RCSID("$OpenBSD: ssh-keygen.c,v 1.88 2001/12/27 18:10:29 markus Exp $"); #include #include @@ -936,10 +936,6 @@ main(int ac, char **av) printf("Too many arguments.\n"); usage(); } - if (key_type_name == NULL) { - printf("You must specify a key type (-t).\n"); - usage(); - } if (change_passphrase && change_comment) { printf("Can only have one of -p and -c.\n"); usage(); @@ -969,6 +965,10 @@ main(int ac, char **av) arc4random_stir(); + if (key_type_name == NULL) { + printf("You must specify a key type (-t).\n"); + usage(); + } type = key_type_from_name(key_type_name); if (type == KEY_UNSPEC) { fprintf(stderr, "unknown key type %s\n", key_type_name); -- cgit v1.2.3