From dc4459a62764d7c2badf0b1b91c1bfb1e188a99e Mon Sep 17 00:00:00 2001 From: millert Date: Tue, 17 Jan 2023 18:52:44 +0000 Subject: [PATCH] For "ssh -V" always exit 0, there is no need to check opt again. This was missed when the fallthrough in the switch case above it was removed. OK deraadt@ --- usr.bin/ssh/ssh.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/usr.bin/ssh/ssh.c b/usr.bin/ssh/ssh.c index 9cbd69afb2f..c931542e3df 100644 --- a/usr.bin/ssh/ssh.c +++ b/usr.bin/ssh/ssh.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ssh.c,v 1.583 2023/01/13 02:58:20 dtucker Exp $ */ +/* $OpenBSD: ssh.c,v 1.584 2023/01/17 18:52:44 millert Exp $ */ /* * Author: Tatu Ylonen * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland @@ -860,8 +860,7 @@ main(int ac, char **av) case 'V': fprintf(stderr, "%s, %s\n", SSH_VERSION, SSH_OPENSSL_VERSION); - if (opt == 'V') - exit(0); + exit(0); break; case 'w': if (options.tun_open == -1) -- 2.20.1