From 2eaa526d66d1d742e23bc5a677b68d5c44123363 Mon Sep 17 00:00:00 2001 From: Thomas Hochstein Date: Mon, 1 Jun 2026 22:00:19 +0200 Subject: [PATCH] Add trailing slash to --datadir, if missing. Signed-off-by: Thomas Hochstein --- ChangeLog | 1 + bin/yapfaq.pl | 3 +++ 2 files changed, 4 insertions(+) diff --git a/ChangeLog b/ChangeLog index 0e8870c..bc428c8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,6 @@ yapfaq 1.1.1 (unreleased) * Warn for missing .rc file. + * Add trailing slash to --datadir, if missing. yapfaq 1.1.0 (2026-02-13) * --test: Set Supersedes and don't modify Message-ID if -o is set. diff --git a/bin/yapfaq.pl b/bin/yapfaq.pl index 80dcbde..ec01ab8 100755 --- a/bin/yapfaq.pl +++ b/bin/yapfaq.pl @@ -120,6 +120,9 @@ if ($OptSimulation) { # -t implies -o if -n is not set $OptOutput = 1 if $OptTest && !$OptNewsgroup; +# add trailing slash to $Config{'datadir'}, if necessary +$Config{'datadir'} .= '/' if $Config{'datadir'} !~ /\/$/; + ### create list of @Projects from $Config{'datadir'} unless -p is set my @Projects; if (!$OptProject) {