From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-Status: No, score=-4.0 required=3.0 tests=ALL_TRUSTED,BAYES_00 shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from localhost (dcvr.yhbt.net [127.0.0.1]) by dcvr.yhbt.net (Postfix) with ESMTP id 5B5C420085 for ; Thu, 31 Dec 2020 13:51:58 +0000 (UTC) From: Eric Wong To: meta@public-inbox.org Subject: [PATCH 35/36] ds: clobber $in_loop first at reset Date: Thu, 31 Dec 2020 13:51:53 +0000 Message-Id: <20201231135154.6070-36-e@80x24.org> In-Reply-To: <20201231135154.6070-1-e@80x24.org> References: <20201231135154.6070-1-e@80x24.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit List-Id: This may help ensure DESTROY callbacks will see in_loop before the others. --- lib/PublicInbox/DS.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/PublicInbox/DS.pm b/lib/PublicInbox/DS.pm index 4f1558c7..8a560ae8 100644 --- a/lib/PublicInbox/DS.pm +++ b/lib/PublicInbox/DS.pm @@ -66,8 +66,9 @@ Reset all state =cut sub Reset { + $in_loop = undef; # first in case DESTROY callbacks use this %DescriptorMap = (); - $in_loop = $wait_pids = $later_queue = $reap_armed = undef; + $wait_pids = $later_queue = $reap_armed = undef; $EXPMAP = {}; $nextq = $ToClose = $later_timer = $exp_timer = undef; $LoopTimeout = -1; # no timeout by default