From owner-freebsd-bugs Mon Jun 21 10:30: 6 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 4D5D31511B for ; Mon, 21 Jun 1999 10:30:03 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id KAA87321; Mon, 21 Jun 1999 10:30:03 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Date: Mon, 21 Jun 1999 10:30:03 -0700 (PDT) Message-Id: <199906211730.KAA87321@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org Cc: From: Garrett Wollman Subject: Re: bin/12311: Sys::Hostname.pm hangs forever Reply-To: Garrett Wollman Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org The following reply was made to PR bin/12311; it has been noted by GNATS. From: Garrett Wollman To: Sheldon Hearn Cc: freebsd-gnats-submit@FreeBSD.ORG Subject: Re: bin/12311: Sys::Hostname.pm hangs forever Date: Mon, 21 Jun 1999 13:22:46 -0400 (EDT) < said: > Your fix definitely makes the problem go away, but what about callers > that really _don't_ want to receive a SIGCHLD? The correct fix is to create a FreeBSD-specific mechanism to get the hostname. (This took me all of ten minutes to do, most of which was deleting all of the cruft h2xs put in that was not needed.) Then, Sys::Hostname gets the following addition: } elsif ($^O eq 'freebsd') { require FreeBSD; $host = "\0" x 1024; # XXX should import MAXHOSTNAMELEN &FreeBSD::gethostname($host, length($host)); } -GAWollman To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message