From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id 4NmdKogFEWOnBwAAbAwnHQ (envelope-from ) for ; Thu, 01 Sep 2022 21:18:32 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id EGiFKogFEWPK6AAA9RJhRA (envelope-from ) for ; Thu, 01 Sep 2022 21:18:32 +0200 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 499901ACD1 for ; Thu, 1 Sep 2022 21:18:32 +0200 (CEST) Received: from localhost ([::1]:37816 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oTphv-0008DV-4I for larch@yhetil.org; Thu, 01 Sep 2022 15:18:31 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:33450) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oTpgZ-0007MN-FM for guix-patches@gnu.org; Thu, 01 Sep 2022 15:17:08 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:54444) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oTpgV-0005OP-5i for guix-patches@gnu.org; Thu, 01 Sep 2022 15:17:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oTpgV-0006cY-0K for guix-patches@gnu.org; Thu, 01 Sep 2022 15:17:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#57513] [PATCH] installer: Fix segfault on double logical partition removal. Resent-From: Josselin Poiret Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 01 Sep 2022 19:17:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57513 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Mathieu Othacehe Cc: 57513-done@debbugs.gnu.org Received: via spool by 57513-done@debbugs.gnu.org id=D57513.166205977425366 (code D ref 57513); Thu, 01 Sep 2022 19:17:02 +0000 Received: (at 57513-done) by debbugs.gnu.org; 1 Sep 2022 19:16:14 +0000 Received: from localhost ([127.0.0.1]:44188 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTpff-0006b0-2I for submit@debbugs.gnu.org; Thu, 01 Sep 2022 15:16:14 -0400 Received: from jpoiret.xyz ([206.189.101.64]:47052) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTpfa-0006aq-VV for 57513-done@debbugs.gnu.org; Thu, 01 Sep 2022 15:16:08 -0400 Received: from authenticated-user (jpoiret.xyz [206.189.101.64]) by jpoiret.xyz (Postfix) with ESMTPA id EF9F5184F2D; Thu, 1 Sep 2022 19:16:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jpoiret.xyz; s=dkim; t=1662059763; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=r3D5CYHaBSts2G+2kNfeP3nhAb+jWc3PCbDdn0KWGYI=; b=P3LAIJFuA63j+Yc0FmWMDSKFs4/izgTQ/t10YrEoLPv7bUCR1GRkJjvbEZRi0ADgd1Q1UW ZG0i+Hci7O73iYssrYT/+22odfQWSK98qd3uG3UoteyK8RkUvRH4MG2sex692+o6YhsS0z zwTeMlaoUPFMpKioNj+zmlA4DIR8aQVf98nsk3tdaZtfD6ZhjhIizNTg01AZ8P+wUR6TnQ IpqAl8auWo7M2/TTtQlaT1oIDed4/wPhbEQRt6HthLfC4e2qh4eHVnXqg38UX0DJRyZ9Er UHZ0Nj5ba2jtE0dJOfgC1ZANX5VVleLrHNMbzEhc5R+GIzBza83DemVLZjsIDw== In-Reply-To: <87y1v32g7g.fsf@gnu.org> References: <87y1v32g7g.fsf@gnu.org> Date: Thu, 01 Sep 2022 21:16:02 +0200 Message-ID: <87tu5qzz0t.fsf@jpoiret.xyz> MIME-Version: 1.0 Content-Type: text/plain X-Spamd-Bar: / X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" Reply-to: Josselin Poiret X-ACL-Warn: , Josselin Poiret via Guix-patches From: Josselin Poiret via Guix-patches via X-Migadu-Flow: FLOW_IN X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1662059912; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:in-reply-to:in-reply-to:references:references: list-id:list-help:list-unsubscribe:list-subscribe:list-post: dkim-signature; bh=r3D5CYHaBSts2G+2kNfeP3nhAb+jWc3PCbDdn0KWGYI=; b=W+47VMr2VEam6EOkSWfn10JWZXQATAmvvZ+X5syhqCSZsTl8VYlExhRj9cjmVACiDag3Lm lP8Sjf0KCm70VYw8i/fRypz91dTWfDBV/ppM9pK3/8ozJo2UHSfRAHNh+Amj+MuP2I9bC5 9qPZ6vXvk1lL71dU0HVz2Ec/fUGXukewDrGmS5m6lLOofRBUqSEktnKHC4P82oKCb79HHf gJIXqcAlLJVDWk44mgJUtPjhTil2oXWh4qfwhByLL+IUTfddoukVw6eI93ZjsyV3N6ZW0m HQ518hbHNYxF05q3UZHfIQ+zB1WL/4Dso8Fb78/YBF3K0VtL1hAuOXkEU9bL/g== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1662059912; a=rsa-sha256; cv=none; b=cJKDezzxZ5lfewv6Wa/KsPfBlsgBI0C8BUzZ84u/N/5J9w66mzSv1TZnCZW7VCW3gBMZlA BpMBlhwWv+BYNUxW+QkWY8CebzPkdic4NjVrih9LgNGq/zh7CHq1BPku4NisCrGDJBQKVY FIplewdN2XwEUmc+ou71wc6BXV6oU4QFJKkAaVtKoiQoMyQtk1arFmBZaQWQroPvWhBKgg cTms0I2JxN4FGg4GhaMLRg+l9gCJrCsUTag4ZU3LSJYmZt2YaGT/rK7JXFV0krTm9FudRM LeedhDSL8KtgFx/gRHF0sKi0T3l3ELZpCdbJb/VkfTRnwfJpQ9P7dV/X2n9PiQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=jpoiret.xyz header.s=dkim header.b=P3LAIJFu; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -3.28 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=jpoiret.xyz header.s=dkim header.b=P3LAIJFu; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: 499901ACD1 X-Spam-Score: -3.28 X-Migadu-Scanner: scn1.migadu.com X-TUID: OYqn91VZ0qV6 Hey Mathieu, Mathieu Othacehe writes: > I was able to reproduce the issue by creating an extended partition > containing a single logical partition using the manual partitioning tool > then, the automatic one right after. > > It resulted in a segfault, which is fixed by your patch, that's a very > nice catch! I have to thank KE0VVT on IRC, who provided a core dump file! This was surprisingly easier to debug than I thought, for those interested, I built the installer using the same Guix commit, and loaded the guile core dump file in gdb. I then used `guix build parted --with-debug-info=parted` and loaded the resulting libparted.so library using `info sections` to find out where the .text of libparted.so was loaded in the core file, and `add-symbol-file /gnu/store/path/to/libparted.so 0xaddress` to load the symbols. That way, I could see that ped_disk_remove_partition was invoked for a disk that had an empty partition list, hence leading me to this double remove problem! > Pushed as 4989f6acff3b3fcfbd9dde3e3c2767bd2cd6d49e. > > Thanks, > > Mathieu Thank you for reviewing this so fast! Best, -- Josselin Poiret