From: martijn Date: Thu, 28 Jan 2021 20:45:14 +0000 (+0000) Subject: Remove print_{debug,verbose} since they're currently unused and I see no X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=ddc6a5392700588d62485ee75267bdf343bd81c4;p=openbsd Remove print_{debug,verbose} since they're currently unused and I see no reason to start using them in the future. OK tb@ --- diff --git a/usr.sbin/snmpd/snmpd.h b/usr.sbin/snmpd/snmpd.h index 994089c10c3..c490ed2fd46 100644 --- a/usr.sbin/snmpd/snmpd.h +++ b/usr.sbin/snmpd/snmpd.h @@ -1,4 +1,4 @@ -/* $OpenBSD: snmpd.h,v 1.92 2021/01/27 07:21:54 deraadt Exp $ */ +/* $OpenBSD: snmpd.h,v 1.93 2021/01/28 20:45:14 martijn Exp $ */ /* * Copyright (c) 2007, 2008, 2012 Reyk Floeter @@ -780,8 +780,6 @@ ssize_t sendtofrom(int, void *, size_t, int, struct sockaddr *, socklen_t, struct sockaddr *, socklen_t); ssize_t recvfromto(int, void *, size_t, int, struct sockaddr *, socklen_t *, struct sockaddr *, socklen_t *); -void print_debug(const char *, ...); -void print_verbose(const char *, ...); const char *log_in6addr(const struct in6_addr *); const char *print_host(struct sockaddr_storage *, char *, size_t); diff --git a/usr.sbin/snmpd/util.c b/usr.sbin/snmpd/util.c index 26a83bec459..fb8bdf20d29 100644 --- a/usr.sbin/snmpd/util.c +++ b/usr.sbin/snmpd/util.c @@ -1,4 +1,4 @@ -/* $OpenBSD: util.c,v 1.10 2020/06/30 17:11:49 martijn Exp $ */ +/* $OpenBSD: util.c,v 1.11 2021/01/28 20:45:14 martijn Exp $ */ /* * Copyright (c) 2014 Bret Stephen Lambert * @@ -152,30 +152,6 @@ recvfromto(int s, void *buf, size_t len, int flags, struct sockaddr *from, return (ret); } -void -print_debug(const char *emsg, ...) -{ - va_list ap; - - if (log_getverbose() > 2) { - va_start(ap, emsg); - vfprintf(stderr, emsg, ap); - va_end(ap); - } -} - -void -print_verbose(const char *emsg, ...) -{ - va_list ap; - - if (log_getverbose()) { - va_start(ap, emsg); - vfprintf(stderr, emsg, ap); - va_end(ap); - } -} - const char * log_in6addr(const struct in6_addr *addr) {