From owner-freebsd-current@freebsd.org Fri Feb 10 13:50:58 2017 Return-Path: Delivered-To: freebsd-current@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 99DBACD89E9 for ; Fri, 10 Feb 2017 13:50:58 +0000 (UTC) (envelope-from iblis@hs.ntnu.edu.tw) Received: from mail.hs.ntnu.edu.tw (mail.hs.ntnu.edu.tw [140.131.149.3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6974B1803 for ; Fri, 10 Feb 2017 13:50:58 +0000 (UTC) (envelope-from iblis@hs.ntnu.edu.tw) Received: by mail.hs.ntnu.edu.tw (Postfix, from userid 800) id 90C501C6473; Fri, 10 Feb 2017 21:50:56 +0800 (CST) Received: from abeing (IP-215-9.cs.nctu.edu.tw [140.113.215.9]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: iblis@hs.ntnu.edu.tw) by mail.hs.ntnu.edu.tw (Postfix) with ESMTPSA id 52D3A1C644A; Fri, 10 Feb 2017 21:50:56 +0800 (CST) Date: Fri, 10 Feb 2017 21:50:55 +0800 From: Iblis Lin To: Mark Martinec Cc: freebsd-current@freebsd.org Subject: Re: r313494 make perl File::Temp broken Message-ID: <20170210135054.GB70284@abeing> References: <20170210130952.GA70284@abeing> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.7.1 (2016-10-04) X-Bogosity: Ham, tests=bogofilter, spamicity=0.339787, version=1.2.4 X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Feb 2017 13:50:58 -0000 On Fri, Feb 10, 2017 at 02:37:05PM +0100, Mark Martinec wrote: > 2017-02-10 14:09, Iblis Lin wrote: > > as not a perl programmer myself. I have no idea what is going on. > > I found this issue while compiling math/openblas. > > > > [iblis@ns]% uname -a > > FreeBSD ns 12.0-CURRENT FreeBSD 12.0-CURRENT #1 r313500: Fri Feb 10 > > 16:39:21 > > CST 2017 root@ns:/usr/obj/usr/src/sys/GENERIC amd64 > > > > [iblis@ns]% cat test.pl > > use File::Temp qw(tempfile); > > $tmpf = new File::Temp( UNLINK => 1 ); > > > > [iblis@ns]% perl test.pl > > Error in tempfile() using template /tmp/XXXXXXXXXX: Could not create > > temp file > > /tmp/dI5uhUsijR: Bad file descriptor at test.pl line 2. > > [...] > > > stat("/tmp/",{ mode=drwxrwxrwt > > ,inode=24317568,size=1024,blksize=32768}) = 0 (0x0) > > stat("/tmp/",{ mode=drwxrwxrwt > > ,inode=24317568,size=1024,blksize=32768}) = 0 (0x0) > > openat(AT_FDCWD,"/tmp/Nn0Epra5ff",O_RDWR|O_EXLOCK|O_NOFOLLOW|O_CREAT|O_EXCL,0600) > > ERR#9 'Bad file descriptor' > > > Perhaps your /tmp is a logical link, and O_NOFOLLOW does not allow that. > > Mark hmm... no, it's no a logical link. I just reverted the file changed in r313494 (sys/kern/vfs_vnops.c), and perl is happy again. -- Iblis Lin 林峻頤