X-Envelope-From: notmuch-bounces@notmuchmail.org  Sat Jun 20 23:33:31 2026
Return-Path: <notmuch-bounces@notmuchmail.org>
X-Original-To: nmbug@yantan.tethera.net
Delivered-To: nmbug@yantan.tethera.net
Received: from yantan.tethera.net (localhost [127.0.0.1])
	by mail.notmuchmail.org (Postfix) with ESMTP id 5356F5F892;
	Sat, 20 Jun 2026 23:33:31 +0000 (UTC)
Received: from phubs.tethera.net (phubs.tethera.net [IPv6:2607:5300:60:3a9d::1])
	by mail.notmuchmail.org (Postfix) with ESMTPS id 6D3FB5F890
	for <notmuch@notmuchmail.org>; Sat, 20 Jun 2026 23:33:27 +0000 (UTC)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tethera.net;
 i=@tethera.net; q=dns/txt; s=2024; t=1781998402; h=from : to : subject
 : in-reply-to : references : date : message-id : mime-version :
 content-type : from; bh=mXaQRqpZWLZgHAfM2tJ8XmuoKATyohRFXGIKzKK+t0g=;
 b=ih6iLakV63of8lcwC0ou9cO7pI5JvZQFjsRla3hETiyKDgUEqi57Q0E7vCb6/0wPUiT+U
 vOab6Cn20b5SVTyw7KL8NnB0VzuOIRZEppz6GqxWLXWV6TB28xGZwfGPUIdJ8AhhKOnEu4a
 ZmDT08k8HJw+7eqekekFGosq8rZ1BSXZ2rFu1sXhLT+luA03UdtuYLDaUsj8gA3CuhX+Bed
 XGNkJDAbNAI3xJ08NfIliOz5gpwP2Yr9kiTkVPss98hD+n7+xNcql+7qe5EwTMA2WY9QOoB
 3z/8vC3+41cuxCRijLWKD6F3fNGutIQ6AEvJQqhgXh61bl28JdwshF9R899w==
Received: from tethera.net (unknown [IPv6:240a:61:1103:8830:8766:3c30:e77b:18d8])
	by phubs.tethera.net (Postfix) with ESMTPS id 16AED1800F7;
	Sat, 20 Jun 2026 20:33:20 -0300 (ADT)
Received: (nullmailer pid 1324513 invoked by uid 1000);
	Sat, 20 Jun 2026 23:33:17 -0000
From: David Bremner <david@tethera.net>
To: Tomi Ollila <tomi.ollila@iki.fi>, Dick Marinus <dick@mrns.nl>, notmuch@notmuchmail.org
Subject: Re: [PATCH 1/2] CLI/reply: use static const for reply_to_map
In-Reply-To: <y12ijeo.9lm4qp-too@iki.fi>
References: <20260617192542.3516741-1-dick@mrns.nl>
 <20260617192542.3516741-2-dick@mrns.nl> <y12ijeo.9lm4qp-too@iki.fi>
Date: Sun, 21 Jun 2026 08:33:17 +0900
Message-ID: <875x3cwzwi.fsf@tethera.net>
MIME-Version: 1.0
Message-ID-Hash: WQ72CNEYTTZMB5VFASXLVLUKAEUZ5JTQ
X-Message-ID-Hash: WQ72CNEYTTZMB5VFASXLVLUKAEUZ5JTQ
X-MailFrom: david@tethera.net
X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-notmuch.notmuchmail.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header
X-Mailman-Version: 3.3.3
Precedence: list
List-Id: "Use and development of the notmuch mail system." <notmuch.notmuchmail.org>
List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
List-Owner: <mailto:notmuch-owner@notmuchmail.org>
List-Post: <mailto:notmuch@notmuchmail.org>
List-Subscribe: <mailto:notmuch-join@notmuchmail.org>
List-Unsubscribe: <mailto:notmuch-leave@notmuchmail.org>
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit

Tomi Ollila <tomi.ollila@iki.fi> writes:

> On Wed, Jun 17 2026, Dick Marinus wrote:
>
>> It's recommended to store these functions in a const struct, for some
>> reason I even got a segmentation fault without this.
>
> The change looks sane (I also checked all references to reply_to_map in
> code). With this the array does not need to create on-the-fly in that
> function but can (even) be created to read-only location at compile-time
> (barring binding to dynamic libs when program starts but still 
> mpu-protected...)
>
> But about the commit message. Who recommends this thing? you? god?
> deepseek? someone(tm)? Looks somewhat vague statement to me.
>
> Then the sigsegv - I don't see why the code before that change would
> sigsegv. Without more details so that it could be reproduced such
> a statement should not be mentioned in commit message.

I think this is probably the bug discussed in

  https://gcc.gnu.org/bugzilla/show_bug.cgi?id=125252
  https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1135526
  https://nmbug.notmuchmail.org/nmweb/show/87pl3e2nvl.fsf%40tethera.net

(more information in the first link).

I did not see anywhere in the bug log (but maybe I missed it) that the
code was actually wrong. If we do decide to make the change to work
around a gcc bug, we should be clear about that.

_______________________________________________
notmuch mailing list -- notmuch@notmuchmail.org
To unsubscribe send an email to notmuch-leave@notmuchmail.org
