From: jsg Date: Wed, 6 Aug 2014 12:29:43 +0000 (+0000) Subject: avoid displaying a NULL pointer X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=30d381cf933ce47101a8fe60db23517366a50564;p=openbsd avoid displaying a NULL pointer ok deraadt@ reyk@ --- diff --git a/usr.sbin/httpd/logger.c b/usr.sbin/httpd/logger.c index 5c9a4d7239e..aa256ed72a2 100644 --- a/usr.sbin/httpd/logger.c +++ b/usr.sbin/httpd/logger.c @@ -1,4 +1,4 @@ -/* $OpenBSD: logger.c,v 1.3 2014/08/05 15:36:59 reyk Exp $ */ +/* $OpenBSD: logger.c,v 1.4 2014/08/06 12:29:43 jsg Exp $ */ /* * Copyright (c) 2014 Reyk Floeter @@ -250,7 +250,7 @@ logger_log(struct imsg *imsg) log = srv_conf->logerror; if (log == NULL || log->log_fd == -1) { - log_warnx("log file %s not opened", log->log_name); + log_warnx("log file %s not opened", log ? log->log_name : ""); return (0); }