From owner-freebsd-bugs Sun Jun 20 16: 0: 4 1999 Delivered-To: freebsd-bugs@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (Postfix) with ESMTP id 8859515194 for ; Sun, 20 Jun 1999 16:00:01 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id QAA99988; Sun, 20 Jun 1999 16:00:01 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from idiom.com (idiom.com [209.157.64.1]) by hub.freebsd.org (Postfix) with ESMTP id 0F5E414FF5 for ; Sun, 20 Jun 1999 15:51:23 -0700 (PDT) (envelope-from muir@idiom.com) Received: (from muir@localhost) by idiom.com (8.9.3/8.9.3) id PAA97334; Sun, 20 Jun 1999 15:51:22 -0700 (PDT) Message-Id: <199906202251.PAA97334@idiom.com> Date: Sun, 20 Jun 1999 15:51:22 -0700 (PDT) From: David Muir Sharnoff Reply-To: muir@idiom.com To: FreeBSD-gnats-submit@freebsd.org X-Send-Pr-Version: 3.2 Subject: bin/12311: Sys::Hostname.pm hangs forever Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org >Number: 12311 >Category: bin >Synopsis: Hostname.pm hangs forever >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Sun Jun 20 16:00:01 PDT 1999 >Closed-Date: >Last-Modified: >Originator: David Muir Sharnoff >Release: FreeBSD 3.2-RELEASE i386 >Organization: Idiom >Environment: >Description: >How-To-Repeat: The following will hang forever perl -MSys::Hostname -e '$SIG{"CHLD"} = "IGNORE"; hostname();' >Fix: I'm not sure what the real problem is, but the following change to Hostname.pm will cause the problem to go away. Index: contrib/perl5/lib/Sys//Hostname.pm =================================================================== RCS file: /usr/cvs/src/contrib/perl5/lib/Sys/Hostname.pm,v retrieving revision 1.1.1.1 diff -c -r1.1.1.1 Hostname.pm *** Hostname.pm 1998/09/09 06:59:55 1.1.1.1 --- Hostname.pm 1999/06/20 22:23:54 *************** *** 94,100 **** # method 3 - trusty old hostname command || eval { local $SIG{__DIE__}; ! $host = `(hostname) 2>/dev/null`; # bsdish } # method 4 - sysV uname command (may truncate) --- 94,100 ---- # method 3 - trusty old hostname command || eval { local $SIG{__DIE__}; ! $host = `hostname 2>/dev/null`; # bsdish } # method 4 - sysV uname command (may truncate) >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message