summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>1996-06-23 13:16:21 +0000
committerderaadt <deraadt@openbsd.org>1996-06-23 13:16:21 +0000
commit9ef24606929fc1f82dade53e5bc5f5f7fe7f4350 (patch)
tree2b5115b5e4af3f6bfb0827cdc663b1a3562d7a67
parentturn off debug options (diff)
downloadwireguard-openbsd-9ef24606929fc1f82dade53e5bc5f5f7fe7f4350.tar.xz
wireguard-openbsd-9ef24606929fc1f82dade53e5bc5f5f7fe7f4350.zip
use _PATH_UNIX for kernel name
-rw-r--r--sbin/savecore/savecore.c10
-rw-r--r--sbin/savecore/savecore_old.c8
2 files changed, 9 insertions, 9 deletions
diff --git a/sbin/savecore/savecore.c b/sbin/savecore/savecore.c
index 2ce1f72db9c..07f6915bd1e 100644
--- a/sbin/savecore/savecore.c
+++ b/sbin/savecore/savecore.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: savecore.c,v 1.4 1996/04/21 23:47:27 deraadt Exp $ */
+/* $OpenBSD: savecore.c,v 1.5 1996/06/23 13:16:21 deraadt Exp $ */
/* $NetBSD: savecore.c,v 1.26 1996/03/18 21:16:05 leo Exp $ */
/*-
@@ -382,8 +382,8 @@ err1: syslog(LOG_WARNING, "%s: %s", path, strerror(errno));
(void)fclose(fp);
/* Create the core file. */
- (void)snprintf(path, sizeof(path), "%s/bsd.%d.core%s",
- dirname, bounds, compress ? ".Z" : "");
+ (void)snprintf(path, sizeof(path), "%s/%s.%d.core%s",
+ dirname, _PATH_UNIX, bounds, compress ? ".Z" : "");
if (compress) {
if ((fp = zopen(path, "w", 0)) == NULL) {
syslog(LOG_ERR, "%s: %s", path, strerror(errno));
@@ -450,8 +450,8 @@ err2: syslog(LOG_WARNING,
/* Copy the kernel. */
ifd = Open(kernel ? kernel : _PATH_UNIX, O_RDONLY);
- (void)snprintf(path, sizeof(path), "%s/bsd.%d%s",
- dirname, bounds, compress ? ".Z" : "");
+ (void)snprintf(path, sizeof(path), "%s/%s.%d%s",
+ dirname, _PATH_UNIX, bounds, compress ? ".Z" : "");
if (compress) {
if ((fp = zopen(path, "w", 0)) == NULL) {
syslog(LOG_ERR, "%s: %s", path, strerror(errno));
diff --git a/sbin/savecore/savecore_old.c b/sbin/savecore/savecore_old.c
index fa23de1661a..dd6abc42851 100644
--- a/sbin/savecore/savecore_old.c
+++ b/sbin/savecore/savecore_old.c
@@ -368,8 +368,8 @@ err1: syslog(LOG_WARNING, "%s: %s", path, strerror(errno));
(void)fclose(fp);
/* Create the core file. */
- (void)snprintf(path, sizeof(path), "%s/bsd.%d.core%s",
- dirname, bounds, compress ? ".Z" : "");
+ (void)snprintf(path, sizeof(path), "%s/%s.%d.core%s",
+ dirname, _PATH_UNIX, bounds, compress ? ".Z" : "");
if (compress) {
if ((fp = zopen(path, "w", 0)) == NULL) {
syslog(LOG_ERR, "%s: %s", path, strerror(errno));
@@ -424,8 +424,8 @@ err2: syslog(LOG_WARNING,
/* Copy the kernel. */
ifd = Open(kernel ? kernel : _PATH_UNIX, O_RDONLY);
- (void)snprintf(path, sizeof(path), "%s/bsd.%d%s",
- dirname, bounds, compress ? ".Z" : "");
+ (void)snprintf(path, sizeof(path), "%s/%s.%d%s",
+ dirname, _PATH_UNIX, bounds, compress ? ".Z" : "");
if (compress) {
if ((fp = zopen(path, "w", 0)) == NULL) {
syslog(LOG_ERR, "%s: %s", path, strerror(errno));