diff options
author | reyk <reyk@openbsd.org> | 2017-01-09 14:49:21 +0000 |
---|---|---|
committer | reyk <reyk@openbsd.org> | 2017-01-09 14:49:21 +0000 |
commit | 871fc12c557cf094bf5ca1277faefd10ad038938 (patch) | |
tree | 9d48cbb6bdcc53c3019df0c2ffb62d382acc929b /usr.sbin/httpd/server.c | |
parent | pf_purge_thread() needs the NET_LOCK(). (diff) | |
download | wireguard-openbsd-871fc12c557cf094bf5ca1277faefd10ad038938.tar.xz wireguard-openbsd-871fc12c557cf094bf5ca1277faefd10ad038938.zip |
Stop accessing verbose and debug variables from log.c directly.
This replaces log_verbose() and "extern int verbose" with the two functions
log_setverbose() and log_getverbose().
Pointed out by benno@
OK krw@ eric@ gilles@ (OK gilles@ for the snmpd bits as well)
Diffstat (limited to 'usr.sbin/httpd/server.c')
-rw-r--r-- | usr.sbin/httpd/server.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/usr.sbin/httpd/server.c b/usr.sbin/httpd/server.c index 6fdb1464138..9afc7c179fa 100644 --- a/usr.sbin/httpd/server.c +++ b/usr.sbin/httpd/server.c @@ -1,4 +1,4 @@ -/* $OpenBSD: server.c,v 1.100 2016/11/17 14:58:37 jsing Exp $ */ +/* $OpenBSD: server.c,v 1.101 2017/01/09 14:49:22 reyk Exp $ */ /* * Copyright (c) 2006 - 2015 Reyk Floeter <reyk@openbsd.org> @@ -1153,14 +1153,13 @@ server_log(struct client *clt, const char *msg) struct server_config *srv_conf = clt->clt_srv_conf; char *ptr = NULL, *vmsg = NULL; int debug_cmd = -1; - extern int verbose; switch (srv_conf->logformat) { case LOG_FORMAT_CONNECTION: debug_cmd = IMSG_LOG_ACCESS; break; default: - if (verbose > 1) + if (log_getverbose() > 1) debug_cmd = IMSG_LOG_ERROR; if (EVBUFFER_LENGTH(clt->clt_log)) { while ((ptr = |