From 9aba037ad27f1ec8e9c37580d23ea7a8944e8ae5 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Mon, 1 Apr 2024 06:49:36 +0000 Subject: lock: get rid of PID guard PID guards for OnDestroy will be the default in an upcoming change. In the meantime, LeiMirror was the only user and didn't actually need it. --- lib/PublicInbox/Lock.pm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'lib/PublicInbox/Lock.pm') diff --git a/lib/PublicInbox/Lock.pm b/lib/PublicInbox/Lock.pm index ddaf3312..2a5a0f30 100644 --- a/lib/PublicInbox/Lock.pm +++ b/lib/PublicInbox/Lock.pm @@ -41,9 +41,9 @@ sub lock_release { # caller must use return value sub lock_for_scope { - my ($self, @single_pid) = @_; + my ($self) = @_; lock_acquire($self) or return; # lock_path not set - PublicInbox::OnDestroy->new(@single_pid, \&lock_release, $self); + PublicInbox::OnDestroy->new(\&lock_release, $self); } sub lock_acquire_fast { @@ -58,9 +58,9 @@ sub lock_release_fast { # caller must use return value sub lock_for_scope_fast { - my ($self, @single_pid) = @_; + my ($self) = @_; lock_acquire_fast($self) or return; # lock_path not set - PublicInbox::OnDestroy->new(@single_pid, \&lock_release_fast, $self); + PublicInbox::OnDestroy->new(\&lock_release_fast, $self); } 1; -- cgit v1.2.3-24-ge0c7