mirror of git://anongit.mindrot.org/openssh.git
upstream: Remove some set but otherwise unused variables, spotted
in -portable by clang 16's -Wunused-but-set-variable. ok djm@ OpenBSD-Commit-ID: 3d943ddf2369b38fbf89f5f19728e7dc1daf3982
This commit is contained in:
parent
1d78d25653
commit
747691604d
6
kex.c
6
kex.c
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: kex.c,v 1.172 2022/02/01 23:32:51 djm Exp $ */
|
||||
/* $OpenBSD: kex.c,v 1.173 2022/11/07 10:05:38 dtucker Exp $ */
|
||||
/*
|
||||
* Copyright (c) 2000, 2001 Markus Friedl. All rights reserved.
|
||||
*
|
||||
|
@ -1215,7 +1215,7 @@ kex_exchange_identification(struct ssh *ssh, int timeout_ms,
|
|||
const char *version_addendum)
|
||||
{
|
||||
int remote_major, remote_minor, mismatch, oerrno = 0;
|
||||
size_t len, i, n;
|
||||
size_t len, n;
|
||||
int r, expect_nl;
|
||||
u_char c;
|
||||
struct sshbuf *our_version = ssh->kex->server ?
|
||||
|
@ -1271,7 +1271,7 @@ kex_exchange_identification(struct ssh *ssh, int timeout_ms,
|
|||
}
|
||||
sshbuf_reset(peer_version);
|
||||
expect_nl = 0;
|
||||
for (i = 0; ; i++) {
|
||||
for (;;) {
|
||||
if (timeout_ms > 0) {
|
||||
r = waitrfd(ssh_packet_get_connection_in(ssh),
|
||||
&timeout_ms);
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
|
||||
/* $OpenBSD: servconf.c,v 1.387 2022/11/07 10:02:59 dtucker Exp $ */
|
||||
/* $OpenBSD: servconf.c,v 1.388 2022/11/07 10:05:39 dtucker Exp $ */
|
||||
/*
|
||||
* Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
|
||||
* All rights reserved
|
||||
|
@ -2501,7 +2501,7 @@ load_server_config(const char *filename, struct sshbuf *conf)
|
|||
char *line = NULL, *cp;
|
||||
size_t linesize = 0;
|
||||
FILE *f;
|
||||
int r, lineno = 0;
|
||||
int r;
|
||||
|
||||
debug2_f("filename %s", filename);
|
||||
if ((f = fopen(filename, "r")) == NULL) {
|
||||
|
@ -2514,7 +2514,6 @@ load_server_config(const char *filename, struct sshbuf *conf)
|
|||
(r = sshbuf_allocate(conf, st.st_size)) != 0)
|
||||
fatal_fr(r, "allocate");
|
||||
while (getline(&line, &linesize, f) != -1) {
|
||||
lineno++;
|
||||
/*
|
||||
* Strip whitespace
|
||||
* NB - preserve newlines, they are needed to reproduce
|
||||
|
|
Loading…
Reference in New Issue