Received: from eggs.gnu.org ([140.186.70.92]:41669) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RxZiH-0003If-Gy for qemu-devel@nongnu.org; Wed, 15 Feb 2012 02:55:43 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RxZiD-0004Uk-2n for qemu-devel@nongnu.org; Wed, 15 Feb 2012 02:55:41 -0500 Received: from indium.canonical.com ([91.189.90.7]:47939) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RxZiC-0004US-P1 for qemu-devel@nongnu.org; Wed, 15 Feb 2012 02:55:37 -0500 Received: from loganberry.canonical.com ([91.189.90.37]) by indium.canonical.com with esmtp (Exim 4.71 #1 (Debian)) id 1RxZiB-0000y2-I4 for ; Wed, 15 Feb 2012 07:55:35 +0000 Received: from loganberry.canonical.com (localhost [127.0.0.1]) by loganberry.canonical.com (Postfix) with ESMTP id 838A92E8041 for ; Wed, 15 Feb 2012 07:55:35 +0000 (UTC) MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Date: Wed, 15 Feb 2012 07:41:10 -0000 From: Serge Hallyn <932539@bugs.launchpad.net> Sender: bounces@canonical.com References: <20120215053702.27719.77637.malonedeb@soybean.canonical.com> Message-Id: <20120215074110.26294.40303.malone@gac.canonical.com> Errors-To: bounces@canonical.com Subject: [Qemu-devel] [Bug 932539] Re: qemu exits with -11 when connecting to a port redirect before the service starts listening Reply-To: Bug 932539 <932539@bugs.launchpad.net> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org inline void insque(void *a, void *b) { register struct quehead *element =3D (struct quehead *) a; register struct quehead *head =3D (struct quehead *) b; element->qh_link =3D head->qh_link; (line 27 is the last line) (gdb) p *element Cannot access memory at address 0x0 (gdb) p a $3 =3D (void *) 0x0 This is called from here in slirp/if.c: /* If there are more packets for this session, re-queue them */ if (ifm->ifs_next !=3D /* ifm->ifs_prev !=3D */ ifm) { insque(ifm->ifs_next, ifqt); ifs_remque(ifm); } It sounds like ifm expects its last element to have ifm->ifs_next =3D ifm, but it's actually =3D=3D NULL. I don't see any changes to this file likely to have introduced the regression, looking further up the stack. ** Also affects: qemu Importance: Undecided Status: New -- = You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/932539 Title: qemu exits with -11 when connecting to a port redirect before the service starts listening Status in QEMU: New Status in =E2=80=9Cqemu-kvm=E2=80=9D package in Ubuntu: Confirmed Bug description: This was detected initially as a crash in the auto upgrade tester. The code of the upgrade tester basically spawns a kvm instance in the bac= kground with a port redirect from localhost:54322 to tcp:22 in the VM, then= wait for that port to allow for a ssh connection before continuing the upg= rade testing. In the past (Oneiric), all worked well but since Precise, we now get qemu exitting with -11 at every single test :( A quick reproducer is: - start a VM that has openssh-server installed with: -net user,hostfwd= =3Dtcp::54322-:22 - immediately start "ssh -p 54322 127.0.0.1" before the VM starts bootin= g (BIOS/GRUB state) Then wait for sshd to start in the VM and qemu will exit with -11. To manage notifications about this bug go to: https://bugs.launchpad.net/qemu/+bug/932539/+subscriptions