GNU bug report logs -
#61670
[PATCH] Improve test for blocked signals
Previous Next
Reported by: Jacob Bachmeyer <jcb <at> gnu.org>
Date: Tue, 21 Feb 2023 05:42:03 UTC
Severity: normal
Tags: patch
Done: Paul Eggert <eggert <at> cs.ucla.edu>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 61670 in the body.
You can then email your comments to 61670 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
automake-patches <at> gnu.org
:
bug#61670
; Package
automake-patches
.
(Tue, 21 Feb 2023 05:42:03 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Jacob Bachmeyer <jcb <at> gnu.org>
:
New bug report received and forwarded. Copy sent to
automake-patches <at> gnu.org
.
(Tue, 21 Feb 2023 05:42:03 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
This fixes ERRORs reported by:
* t/parallel-tests-interrupt.tap
* t/self-check-exit.tap
* t/self-check-is-blocked-signal.tap
* t/tap-signal.tap
* t/ax/am-test-lib.sh (is_blocked_signal): Revise Perl code
to more closely follow documented interfaces where
available. This also works around bugs and limitations
of the POSIX module in Perl 5.6.
---
t/ax/am-test-lib.sh | 15 ++++++++-------
1 file changed, 8 insertions(+), 7 deletions(-)
diff --git a/t/ax/am-test-lib.sh b/t/ax/am-test-lib.sh
index bdf699889..bfa1d84b2 100644
--- a/t/ax/am-test-lib.sh
+++ b/t/ax/am-test-lib.sh
@@ -103,13 +103,14 @@ is_blocked_signal ()
# Use perl, since trying to do this portably in the shell can be
# very tricky, if not downright impossible. For reference, see:
# <https://lists.gnu.org/archive/html/bug-autoconf/2011-09/msg00004.html>
- if $PERL -w -e '
- use strict;
- use warnings FATAL => "all";
- use POSIX;
- my %oldsigaction = ();
- sigaction('"$1"', 0, \%oldsigaction);
- exit ($oldsigaction{"HANDLER"} eq "IGNORE" ? 0 : 77);
+ if $PERL -Mstrict -Mwarnings=FATAL,all -MPOSIX -Mconstant=SN,"$1" -e '
+ my $new = POSIX::SigAction->new(sub {});
+ my $old = POSIX::SigAction->new();
+ { no warnings q[uninitialized]; sigaction(SN, $new, $old) }
+ my $oldhandler;
+ if ($old->can(q[handler])) { $oldhandler = $old->handler }
+ else { $oldhandler = $old->{HANDLER} }
+ exit ($oldhandler eq "IGNORE" ? 0 : 77);
'; then
return 0
elif test $? -eq 77; then
--
2.17.1
Reply sent
to
Paul Eggert <eggert <at> cs.ucla.edu>
:
You have taken responsibility.
(Wed, 29 Mar 2023 19:56:02 GMT)
Full text and
rfc822 format available.
Notification sent
to
Jacob Bachmeyer <jcb <at> gnu.org>
:
bug acknowledged by developer.
(Wed, 29 Mar 2023 19:56:02 GMT)
Full text and
rfc822 format available.
Message #10 received at 61670-done <at> debbugs.gnu.org (full text, mbox):
Thanks, I installed that patch into Automake.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Thu, 27 Apr 2023 11:24:10 GMT)
Full text and
rfc822 format available.
This bug report was last modified 2 years and 17 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.