From 3c1db6da25d8fb80057a3727acf12d8752b32d09 Mon Sep 17 00:00:00 2001 From: bde Date: Mon, 14 Nov 1994 07:51:11 +0000 Subject: Don't build an unused array of kernel names when HAVE_GETBOOTFILE is defined. Don't use the newfangled C features to waste time building the array at runtime when HAVE_GETBOOTFILE is not defined. --- usr.sbin/xntpd/util/tickadj.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'usr.sbin/xntpd') diff --git a/usr.sbin/xntpd/util/tickadj.c b/usr.sbin/xntpd/util/tickadj.c index 41d4c46..75d2ab7 100644 --- a/usr.sbin/xntpd/util/tickadj.c +++ b/usr.sbin/xntpd/util/tickadj.c @@ -430,7 +430,8 @@ getoffsets(filex, tick_off, tickadj_off, dosync_off, noprintf_off) {""}, }; #endif - char *kernels[] = { +#ifndef HAVE_GETBOOTFILE + static char *kernels[] = { "/kernel", "/vmunix", "/unix", @@ -440,6 +441,7 @@ getoffsets(filex, tick_off, tickadj_off, dosync_off, noprintf_off) "/netbsd", NULL }; +#endif struct stat stbuf; #ifdef HAVE_GETBOOTFILE -- cgit v1.1