diff options
author | Eric Wong <e@80x24.org> | 2020-12-26 08:12:52 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2020-12-26 19:27:15 +0000 |
commit | b5e960f50289434025f5904c8c1311e4c8a02b82 (patch) | |
tree | 2ad8a4f875dee02ea062bf3cb7f35e179d724eb7 /lib | |
parent | 10bf54305da8422d9ece6b809996092c1c4b1786 (diff) | |
download | public-inbox-b5e960f50289434025f5904c8c1311e4c8a02b82.tar.gz |
->on_inbox_unlock callbacks could clobber $_, and this seems to fix a problem with -extindex --watch failing to index some inboxes after SIGHUP reload.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/PublicInbox/Inbox.pm | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/PublicInbox/Inbox.pm b/lib/PublicInbox/Inbox.pm index ec8469e3..1b9b56ff 100644 --- a/lib/PublicInbox/Inbox.pm +++ b/lib/PublicInbox/Inbox.pm @@ -414,8 +414,8 @@ sub on_unlock { my ($self) = @_; check_inodes($self); my $subs = $self->{unlock_subs} or return; - for (values %$subs) { - eval { $_->on_inbox_unlock($self) }; + for my $obj (values %$subs) { + eval { $obj->on_inbox_unlock($self) }; warn "E: $@ ($self->{inboxdir})\n" if $@; } } |