From 484fbc57524facc01b11fbe3c2ee35f5170e7ec5 Mon Sep 17 00:00:00 2001 From: espie Date: Sat, 23 Dec 2017 12:35:47 +0000 Subject: [PATCH] the trick to get signal names requires skipping over POSIX stuff we don't have now. as seen by landry@ --- usr.sbin/pkg_add/OpenBSD/State.pm | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/usr.sbin/pkg_add/OpenBSD/State.pm b/usr.sbin/pkg_add/OpenBSD/State.pm index 114b3001524..7871441baa5 100644 --- a/usr.sbin/pkg_add/OpenBSD/State.pm +++ b/usr.sbin/pkg_add/OpenBSD/State.pm @@ -1,5 +1,5 @@ # ex:ts=8 sw=4: -# $OpenBSD: State.pm,v 1.47 2017/11/01 18:18:10 espie Exp $ +# $OpenBSD: State.pm,v 1.48 2017/12/23 12:35:47 espie Exp $ # # Copyright (c) 2007-2014 Marc Espie # @@ -383,7 +383,10 @@ sub fillup_names for my $sym (keys %POSIX::) { next unless $sym =~ /^SIG([A-Z].*)/; - $signal_name[eval "&POSIX::$sym()"] = $1; + my $value = eval "&POSIX::$sym()"; + # skip over POSIX stuff we don't have like SIGRT or SIGPOLL + next unless defined $value; + $signal_name[$value] = $1; } # extra BSD signals $signal_name[5] = 'TRAP'; -- 2.20.1