openbsd-ports/sysutils/nut/patches/patch-clients_upsstats_c

22 lines
668 B
Plaintext
Raw Normal View History

$OpenBSD: patch-clients_upsstats_c,v 1.3 2004/09/27 03:10:24 marcm Exp $
--- clients/upsstats.c.orig Mon Sep 29 21:50:10 2003
+++ clients/upsstats.c Thu Sep 16 08:48:42 2004
@@ -658,7 +658,7 @@ static void display_template(const char
{
char fn[SMALLBUF], buf[LARGEBUF];
- snprintf(fn, sizeof(fn), "%s/%s", confpath(), tfn);
+ snprintf(fn, sizeof(fn), "%s/%s", cgiconfpath(), tfn);
tf = fopen(fn, "r");
@@ -715,7 +715,7 @@ static void load_hosts_conf(void)
char fn[SMALLBUF];
PCONF_CTX ctx;
- snprintf(fn, sizeof(fn), "%s/hosts.conf", CONFPATH);
+ snprintf(fn, sizeof(fn), "%s/hosts.conf", cgiconfpath());
pconf_init(&ctx, upsstats_hosts_err);