summaryrefslogtreecommitdiff
path: root/sshd.c
diff options
context:
space:
mode:
authordjm@openbsd.org <djm@openbsd.org>2019-01-17 01:50:24 +0000
committerDamien Miller <djm@mindrot.org>2019-01-17 13:01:25 +1100
commitdbb4dec6d5d671b5e9d67ef02162a610ad052068 (patch)
treeb743e12829724d70e61a893c565df19dd3200847 /sshd.c
parent60d8c84e0887514c99c9ce071965fafaa1c3d34a (diff)
upstream: many of the global variables in this file can be made static;
patch from Markus Schmidt OpenBSD-Commit-ID: f3db619f67beb53257b21bac0e92b4fb7d5d5737
Diffstat (limited to 'sshd.c')
-rw-r--r--sshd.c32
1 files changed, 16 insertions, 16 deletions
diff --git a/sshd.c b/sshd.c
index 3461383a0..1d25c88f3 100644
--- a/sshd.c
+++ b/sshd.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: sshd.c,v 1.520 2018/12/27 03:25:25 djm Exp $ */ 1/* $OpenBSD: sshd.c,v 1.521 2019/01/17 01:50:24 djm Exp $ */
2/* 2/*
3 * Author: Tatu Ylonen <ylo@cs.hut.fi> 3 * Author: Tatu Ylonen <ylo@cs.hut.fi>
4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland 4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -151,38 +151,38 @@ int debug_flag = 0;
151 * configuration, optionally using connection information provided by the 151 * configuration, optionally using connection information provided by the
152 * "-C" flag. 152 * "-C" flag.
153 */ 153 */
154int test_flag = 0; 154static int test_flag = 0;
155 155
156/* Flag indicating that the daemon is being started from inetd. */ 156/* Flag indicating that the daemon is being started from inetd. */
157int inetd_flag = 0; 157static int inetd_flag = 0;
158 158
159/* Flag indicating that sshd should not detach and become a daemon. */ 159/* Flag indicating that sshd should not detach and become a daemon. */
160int no_daemon_flag = 0; 160static int no_daemon_flag = 0;
161 161
162/* debug goes to stderr unless inetd_flag is set */ 162/* debug goes to stderr unless inetd_flag is set */
163int log_stderr = 0; 163static int log_stderr = 0;
164 164
165/* Saved arguments to main(). */ 165/* Saved arguments to main(). */
166char **saved_argv; 166static char **saved_argv;
167int saved_argc; 167static int saved_argc;
168 168
169/* re-exec */ 169/* re-exec */
170int rexeced_flag = 0; 170static int rexeced_flag = 0;
171int rexec_flag = 1; 171static int rexec_flag = 1;
172int rexec_argc = 0; 172static int rexec_argc = 0;
173char **rexec_argv; 173static char **rexec_argv;
174 174
175/* 175/*
176 * The sockets that the server is listening; this is used in the SIGHUP 176 * The sockets that the server is listening; this is used in the SIGHUP
177 * signal handler. 177 * signal handler.
178 */ 178 */
179#define MAX_LISTEN_SOCKS 16 179#define MAX_LISTEN_SOCKS 16
180int listen_socks[MAX_LISTEN_SOCKS]; 180static int listen_socks[MAX_LISTEN_SOCKS];
181int num_listen_socks = 0; 181static int num_listen_socks = 0;
182 182
183/* Daemon's agent connection */ 183/* Daemon's agent connection */
184int auth_sock = -1; 184int auth_sock = -1;
185int have_agent = 0; 185static int have_agent = 0;
186 186
187/* 187/*
188 * Any really sensitive data in the application is contained in this 188 * Any really sensitive data in the application is contained in this
@@ -214,8 +214,8 @@ u_int session_id2_len = 0;
214u_int utmp_len = HOST_NAME_MAX+1; 214u_int utmp_len = HOST_NAME_MAX+1;
215 215
216/* options.max_startup sized array of fd ints */ 216/* options.max_startup sized array of fd ints */
217int *startup_pipes = NULL; 217static int *startup_pipes = NULL;
218int startup_pipe; /* in child */ 218static int startup_pipe; /* in child */
219 219
220/* variables used for privilege separation */ 220/* variables used for privilege separation */
221int use_privsep = -1; 221int use_privsep = -1;