From owner-freebsd-bugs@FreeBSD.ORG Tue Sep 24 22:30:02 2013 Return-Path: Delivered-To: freebsd-bugs@smarthost.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 4F706339 for ; Tue, 24 Sep 2013 22:30:02 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 29A872101 for ; Tue, 24 Sep 2013 22:30:02 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.7/8.14.7) with ESMTP id r8OMU2aV097152 for ; Tue, 24 Sep 2013 22:30:02 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.7/8.14.7/Submit) id r8OMU1CJ097151; Tue, 24 Sep 2013 22:30:01 GMT (envelope-from gnats) Resent-Date: Tue, 24 Sep 2013 22:30:01 GMT Resent-Message-Id: <201309242230.r8OMU1CJ097151@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Jeremy Chadwick Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 7B74BDC5 for ; Tue, 24 Sep 2013 22:20:49 +0000 (UTC) (envelope-from jdc@koitsu.org) Received: from relay4-d.mail.gandi.net (relay4-d.mail.gandi.net [217.70.183.196]) by mx1.freebsd.org (Postfix) with ESMTP id 1363B209F for ; Tue, 24 Sep 2013 22:20:48 +0000 (UTC) Received: from mfilter13-d.gandi.net (mfilter13-d.gandi.net [217.70.178.141]) by relay4-d.mail.gandi.net (Postfix) with ESMTP id BD08317207C for ; Wed, 25 Sep 2013 00:20:31 +0200 (CEST) Received: from relay4-d.mail.gandi.net ([217.70.183.196]) by mfilter13-d.gandi.net (mfilter13-d.gandi.net [10.0.15.180]) (amavisd-new, port 10024) with ESMTP id qXJNqb52SMeJ for ; Wed, 25 Sep 2013 00:20:29 +0200 (CEST) Received: from jdc.koitsu.org (c-76-102-14-35.hsd1.ca.comcast.net [76.102.14.35]) (Authenticated sender: jdc@koitsu.org) by relay4-d.mail.gandi.net (Postfix) with ESMTPSA id C6E22172080 for ; Wed, 25 Sep 2013 00:20:29 +0200 (CEST) Received: by icarus.home.lan (Postfix, from userid 1000) id 352DA73A1B; Tue, 24 Sep 2013 15:20:28 -0700 (PDT) Message-Id: <20130924222028.352DA73A1B@icarus.home.lan> Date: Tue, 24 Sep 2013 15:20:28 -0700 (PDT) From: Jeremy Chadwick To: FreeBSD-gnats-submit@freebsd.org X-Send-Pr-Version: 3.114 Subject: bin/182360: nslookup emits SIGSEGV when Ctrl-D (EOF) pressed X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: Jeremy Chadwick List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 24 Sep 2013 22:30:02 -0000 >Number: 182360 >Category: bin >Synopsis: nslookup emits SIGSEGV when Ctrl-D (EOF) pressed >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Tue Sep 24 22:30:00 UTC 2013 >Closed-Date: >Last-Modified: >Originator: Jeremy Chadwick >Release: FreeBSD 9.2-PRERELEASE amd64 >Organization: >Environment: System: FreeBSD icarus.home.lan 9.2-PRERELEASE FreeBSD 9.2-PRERELEASE #0 r255608: Mon Sep 16 00:47:48 PDT 2013 root@icarus.home.lan:/usr/obj/usr/src/sys/X7SBA_RELENG_9_amd64 amd64 >Description: nslookup crashes (SIGSEGV/sig11) when Ctrl-D (EOF) is entered any time during the interactive prompt. I can reproduce this on two completely separate amd64 9.2-PRERELEASE systems (one is r255608, another is r255864), on completely different hardware. Not sure if this issue is caused by introduced bugs/changes in libedit, or in recent versions of BIND that have been imported. I do not build my systems' /lib with debug symbols enabled so tracking this down is something someone with debug symbols will need to do (unless they can look at the code and know what's wrong). If one thinks this is a system configuration issue, I can provide /etc/make.conf and /etc/src.conf (the only two relevant file I can think of) if asked. Validation and a stack trace is below: $ nslookup > ^DSegmentation fault: 11 (core dumped) $ ls -l nslookup.core -rw------- 1 jdc users 13996032 Sep 24 15:16 nslookup.core $ gdb /usr/bin/nslookup nslookup.core GNU gdb 6.1.1 [FreeBSD] Copyright 2004 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "amd64-marcel-freebsd"...(no debugging symbols found)... Core was generated by `nslookup'. Program terminated with signal 11, Segmentation fault. Reading symbols from /lib/libedit.so.7...(no debugging symbols found)...done. Loaded symbols for /lib/libedit.so.7 Reading symbols from /lib/libcrypto.so.6...(no debugging symbols found)...done. Loaded symbols for /lib/libcrypto.so.6 Reading symbols from /lib/libthr.so.3...(no debugging symbols found)...done. Loaded symbols for /lib/libthr.so.3 Reading symbols from /lib/libgcc_s.so.1...(no debugging symbols found)...done. Loaded symbols for /lib/libgcc_s.so.1 Reading symbols from /lib/libc.so.7...(no debugging symbols found)...done. Loaded symbols for /lib/libc.so.7 Reading symbols from /lib/libncurses.so.8...(no debugging symbols found)...done. Loaded symbols for /lib/libncurses.so.8 Reading symbols from /libexec/ld-elf.so.1...(no debugging symbols found)...done. Loaded symbols for /libexec/ld-elf.so.1 #0 0x00000008014e61ab in strlen () from /lib/libc.so.7 [New Thread 801c08000 (LWP 101041/nslookup)] [New Thread 801c07c00 (LWP 101040/nslookup)] [New Thread 801c07800 (LWP 101039/nslookup)] [New Thread 801c07400 (LWP 100757/nslookup)] (gdb) bt #0 0x00000008014e61ab in strlen () from /lib/libc.so.7 #1 0x0000000801461a7e in strdup () from /lib/libc.so.7 #2 0x00000008009f3dfb in history () from /lib/libedit.so.7 #3 0x00000008009f3735 in history () from /lib/libedit.so.7 #4 0x00000008009e1fbf in add_history () from /lib/libedit.so.7 #5 0x000000000040eacd in getinput () #6 0x000000000054df38 in run () #7 0x0000000800fb9e10 in pthread_getprio () from /lib/libthr.so.3 #8 0x0000000000000000 in ?? () (gdb) >How-To-Repeat: 1. Run nslookup 2. Press Ctrl-D (EOF) >Fix: >Release-Note: >Audit-Trail: >Unformatted: