diff options
-rw-r--r-- | usr.sbin/newsyslog/newsyslog.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.sbin/newsyslog/newsyslog.c b/usr.sbin/newsyslog/newsyslog.c index 590dbf6..632cc6a 100644 --- a/usr.sbin/newsyslog/newsyslog.c +++ b/usr.sbin/newsyslog/newsyslog.c @@ -340,7 +340,7 @@ init_entry(const char *fname, struct conf_entry *src_entry) if (tempwork == NULL) err(1, "malloc of conf_entry for %s", fname); - if (destdir == NULL) + if (destdir == NULL || fname[0] != '/') tempwork->log = strdup(fname); else asprintf(&tempwork->log, "%s%s", destdir, fname); |