It doesn't seem worth it to keep pathnames.h around (especially when it has
non-static data)
This commit is contained in:
parent
c7bc0cd0aa
commit
a9d4845398
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: newsyslog.c,v 1.52 2007/12/21 06:25:19 simonb Exp $ */
|
||||
/* $NetBSD: newsyslog.c,v 1.53 2007/12/21 06:46:31 dogcow Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1999, 2000 Andrew Doran <ad@NetBSD.org>
|
||||
|
@ -55,7 +55,7 @@
|
|||
|
||||
#include <sys/cdefs.h>
|
||||
#ifndef lint
|
||||
__RCSID("$NetBSD: newsyslog.c,v 1.52 2007/12/21 06:25:19 simonb Exp $");
|
||||
__RCSID("$NetBSD: newsyslog.c,v 1.53 2007/12/21 06:46:31 dogcow Exp $");
|
||||
#endif /* not lint */
|
||||
|
||||
#include <sys/types.h>
|
||||
|
@ -79,8 +79,6 @@ __RCSID("$NetBSD: newsyslog.c,v 1.52 2007/12/21 06:25:19 simonb Exp $");
|
|||
#include <err.h>
|
||||
#include <paths.h>
|
||||
|
||||
#include "pathnames.h"
|
||||
|
||||
#define PRHDRINFO(x) \
|
||||
(/*LINTED*/(void)(verbose ? printf x : 0))
|
||||
#define PRINFO(x) \
|
||||
|
@ -109,6 +107,23 @@ struct conf_entry {
|
|||
char logfile[MAXPATHLEN]; /* Path to log file */
|
||||
};
|
||||
|
||||
struct compressor {
|
||||
const char *path;
|
||||
const char *args;
|
||||
const char *suffix;
|
||||
const char *flag; /* newsyslog.conf flag */
|
||||
};
|
||||
|
||||
static struct compressor compress[] =
|
||||
{
|
||||
{NULL, "", "", ""}, /* 0th compressor is "no compression" */
|
||||
{"/usr/bin/gzip", "-f", ".gz", "Z"},
|
||||
{"/usr/bin/bzip2", "-9f", ".bz2", "J"},
|
||||
};
|
||||
|
||||
#define _PATH_NEWSYSLOGCONF "/etc/newsyslog.conf"
|
||||
#define _PATH_SYSLOGDPID _PATH_VARRUN"syslogd.pid"
|
||||
|
||||
static int verbose; /* Be verbose */
|
||||
static int noaction; /* Take no action */
|
||||
static int nosignal; /* Do not send signals */
|
||||
|
|
|
@ -1,46 +0,0 @@
|
|||
/* $NetBSD: pathnames.h,v 1.3 2007/12/21 05:40:59 dogcow Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1999, 2000 Andrew Doran <ad@NetBSD.org>
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
* are met:
|
||||
* 1. Redistributions of source code must retain the above copyright
|
||||
* notice, this list of conditions and the following disclaimer.
|
||||
* 2. Redistributions in binary form must reproduce the above copyright
|
||||
* notice, this list of conditions and the following disclaimer in the
|
||||
* documentation and/or other materials provided with the distribution.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
|
||||
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
||||
* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
||||
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
*/
|
||||
|
||||
#define _PATH_NEWSYSLOGCONF "/etc/newsyslog.conf"
|
||||
#define _PATH_SYSLOGDPID _PATH_VARRUN"syslogd.pid"
|
||||
|
||||
struct compressor {
|
||||
const char *path;
|
||||
const char *args;
|
||||
const char *suffix;
|
||||
const char *flag; /* i.e. newsyslog flag to activate compressor */
|
||||
};
|
||||
|
||||
struct compressor compress[] =
|
||||
{
|
||||
{NULL, "", "", ""}, /* 0th compressor is "no compression" */
|
||||
{"/usr/bin/gzip", "-f", ".gz", "Z"},
|
||||
{"/usr/bin/bzip2", "-9f", ".bz2", "J"},
|
||||
};
|
||||
|
Loading…
Reference in New Issue