about summary refs log tree commit homepage
path: root/lib/PublicInbox/Admin.pm
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2020-12-22 06:01:44 +0000
committerEric Wong <e@80x24.org>2020-12-22 22:56:03 +0000
commit949e8b4a65a2dbb99d8923ebb4715a8724ca8bf2 (patch)
tree367bec9109d827c9fcb726b0aba859aba188f65a /lib/PublicInbox/Admin.pm
parent1350f5ab09f72c75ac2cd6c88f6a2b9e198fef55 (diff)
downloadpublic-inbox-949e8b4a65a2dbb99d8923ebb4715a8724ca8bf2.tar.gz
Some of my ancient v1-only scripts called public-inbox-index
to operate on GIT_DIR:

	GIT_DIR=/path/to/foo.git public-inbox-index

This change ensures they keep working, otherwise "." will be
passed to the --git-dir= switch of git(1) because that's the
default directory if no inboxes are specified on the
command-line.

Fixes: 9fcce78e40b0a7c6 ("script/public-inbox-*: favor caller-provided pathnames")
Diffstat (limited to 'lib/PublicInbox/Admin.pm')
-rw-r--r--lib/PublicInbox/Admin.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/PublicInbox/Admin.pm b/lib/PublicInbox/Admin.pm
index c972fb68..9a86d206 100644
--- a/lib/PublicInbox/Admin.pm
+++ b/lib/PublicInbox/Admin.pm
@@ -127,7 +127,7 @@ sub resolve_inboxes ($;$$) {
                 for (my $i = 0; $i <= $#dirs; $i++) {
                         my $dir = $dirs[$i];
                         my @st = stat($dir) or die "stat($dir): $!\n";
-                        $dir = resolve_inboxdir($dir, \(my $ver));
+                        $dir = $dirs[$i] = resolve_inboxdir($dir, \(my $ver));
                         if ($ver >= $min_ver) {
                                 $s2i{"$st[0]\0$st[1]"} //= $i;
                         } else {