From unknown Sun Jun 22 22:42:38 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#50126 <50126@debbugs.gnu.org> To: bug#50126 <50126@debbugs.gnu.org> Subject: Status: 28.0.50; "mode: conf" and "mode: tex" get unbounded recursion Reply-To: bug#50126 <50126@debbugs.gnu.org> Date: Mon, 23 Jun 2025 05:42:38 +0000 retitle 50126 28.0.50; "mode: conf" and "mode: tex" get unbounded recursion reassign 50126 emacs submitter 50126 Bob Rogers severity 50126 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Thu Aug 19 13:13:40 2021 Received: (at submit) by debbugs.gnu.org; 19 Aug 2021 17:13:40 +0000 Received: from localhost ([127.0.0.1]:60778 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mGlbn-0000JM-PX for submit@debbugs.gnu.org; Thu, 19 Aug 2021 13:13:40 -0400 Received: from lists.gnu.org ([209.51.188.17]:41768) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mGla5-0000GH-H6 for submit@debbugs.gnu.org; Thu, 19 Aug 2021 13:11:53 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34978) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mGla5-0001dj-75 for bug-gnu-emacs@gnu.org; Thu, 19 Aug 2021 13:11:53 -0400 Received: from mail-qk1-x730.google.com ([2607:f8b0:4864:20::730]:34759) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mGla2-00069N-HC for bug-gnu-emacs@gnu.org; Thu, 19 Aug 2021 13:11:52 -0400 Received: by mail-qk1-x730.google.com with SMTP id n11so7944760qkk.1 for ; Thu, 19 Aug 2021 10:11:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rgrjr-com.20150623.gappssmtp.com; s=20150623; h=mime-version:content-transfer-encoding:message-id:date:from:to :subject; bh=EKc9cJmrcEls70YR3P6G0+Af3oc2mx9ySQGoiCv1KN0=; b=hJXaSvWFFSr+Z/u2Zz7/Iu6MTbKjfdXzmRAATgr4iwdHfqXAcPVSJf14BYFtylpvx7 6Uowjoqe2JWBtIOPjXdOaYHUDU1tDKBoTfFM7NhpVJOmDrpf07vDGu6ZHVm9B6n3Jjlf bizMdjNprrF0J8slfbvHyEK5LW4Hh2Jtw44UE9j8EUdvBLeeFSZ4twiskHo6Whu1ThyD To/WbKBlgxXrxai0RMECI6yloFjQlzPvpjeYo0IZQvEpDp5HW0Sc0LqP7FAAC2y+10QZ H7N/6MsLSf8egUwu6MES20I0IrFkp0nE6LPQ4GvPlRvR3gHVkG42MlNL2npWfpsfnVlY Jstg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:content-transfer-encoding :message-id:date:from:to:subject; bh=EKc9cJmrcEls70YR3P6G0+Af3oc2mx9ySQGoiCv1KN0=; b=UEsJznPuIk5r/AH5asxE+N9QZ/0BYDxTeeZBh0Ujx047ho+PlnsfrdfeGAuRLayzMw ZV2DQiXfFUI+bLwgWxo7wHb1NaiK3u5VxuFlo+7qG49v2Pu21SAybngax76weaysdNwc pcl4sUTSwddXMs6t+IHa3mFJYWZnvuPtzhLifGp0CItEBb5/pZK0cpy7KydF+iuveGRQ yZe7Cxp6m+Bs/u6vuSgaQHCsZa4Ibe6JwGK0UghJnyZlqv5ZEbEITQZuPHtR/SBTzWJw CTA+EIxOVJLWgTcmgpQpWZkkhZovdk1zsvuBjKE1SUNw1LVxn7y6r8B7hXzP4L9iQM83 cp2g== X-Gm-Message-State: AOAM531lfKxrXw1l1FXQWnQZNnMJwp139A4JHClyORG+OLF+LMEf6lbL vodsJhDEfEItPOr/jDnMZEezxH8kvBwFZcfT X-Google-Smtp-Source: ABdhPJyEy8J4e1+m5waNTyPbkz5SStCA4p+OVisufMTkITBHjeNsYCfCsuZcYNw1XNvQ21LKxHlBJQ== X-Received: by 2002:a37:6197:: with SMTP id v145mr4701941qkb.487.1629393106743; Thu, 19 Aug 2021 10:11:46 -0700 (PDT) Received: from orion.rgrjr.com ([2601:19c:4600:3270::4]) by smtp.gmail.com with ESMTPSA id m19sm1440646qtx.84.2021.08.19.10.11.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Aug 2021 10:11:46 -0700 (PDT) MIME-Version: 1.0 Content-Type: text/plain; charset=unknown Content-Transfer-Encoding: 7bit Message-ID: <24862.37073.150567.609831@orion.rgrjr.com> Date: Thu, 19 Aug 2021 13:11:45 -0400 From: Bob Rogers To: bug-gnu-emacs@gnu.org Subject: 28.0.50; "mode: conf" and "mode: tex" get unbounded recursion X-Mailer: VM 7.19 under Emacs 28.0.50 Received-SPF: none client-ip=2607:f8b0:4864:20::730; envelope-from=rogers@rgrjr.com; helo=mail-qk1-x730.google.com X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_NONE=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Thu, 19 Aug 2021 13:13:37 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) In "emacs -Q" in master rebuilt a few hours ago, when I open the file shown below with "# -*- mode: conf; -*-" I get a "Lisp nesting exceeds max-lisp-eval-depth " error because conf-mode is trying to dispatch to one of its submodes, but the submode then calls run-mode-hooks which ends up back in conf-mode, ad inf. Using this minimal broken.conf file: # -*- mode: conf; -*- is sufficient; here's the top of the backtrace: Debugger entered--Lisp error: (error "Lisp nesting exceeds max-lisp-eval-depth ") apply(#f(compiled-function (orig-fun) "Redirect to one of the submodes when called directly." #) #f(compiled-function () (interactive nil) #) nil) conf-mode() conf-unix-mode() #f(compiled-function (orig-fun) "Redirect to one of the submodes when called directly." #)(#f(compiled-function () (interactive nil) #)) apply(#f(compiled-function (orig-fun) "Redirect to one of the submodes when called directly." #) #f(compiled-function () (interactive nil) #) nil) conf-mode() hack-one-local-variable(mode conf) hack-local-variables-apply() hack-local-variables(no-mode) run-mode-hooks(conf-unix-mode-hook) conf-unix-mode() #f(compiled-function (orig-fun) "Redirect to one of the submodes when called directly." #)(#f(compiled-function () (interactive nil) #)) apply(#f(compiled-function (orig-fun) "Redirect to one of the submodes when called directly." #) #f(compiled-function () (interactive nil) #) nil) conf-mode() hack-one-local-variable(mode conf) . . . It fails with conf-unix-mode in the simple case of the configuration file above; unsurprisingly, I've also seen it fail with conf-space-mode. And "mode: tex;" has the same general problem, since it uses the same dispatch logic. I would attempt a patch, but I have no clue what TRT would be here. It would seem cleanest to keep conf-mode and tex-mode as user-visible modes, and make new generic-conf-mode and generic-tex-mode parents for their submodes, but that seems like it could be a fairly large change. Using delay-mode-hooks might be simpler, but I have no idea how that would work. -- Bob Rogers http://www.rgrjr.com/ ------------------------------------------------------------------------ In GNU Emacs 28.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.20, cairo version 1.16.0) of 2021-08-19 built on orion Repository revision: a44432a773f7e131692e3f5c9d765cffeef0739a Repository branch: master Windowing system distributor 'The X.Org Foundation', version 11.0.12003000 System Description: openSUSE Leap 15.3 Configured using: 'configure --with-dbus=no --with-gsettings=no --with-gif=ifavailable --with-tiff=no --with-gnutls=yes --with-gconf=no' Configured features: ACL CAIRO FREETYPE GIF GLIB GMP GNUTLS HARFBUZZ JPEG LIBSELINUX LIBXML2 MODULES NOTIFY INOTIFY PDUMPER PNG RSVG SECCOMP SOUND THREADS TOOLKIT_SCROLL_BARS X11 XDBE XIM XPM GTK3 ZLIB Important settings: value of $LANG: en_US.UTF-8 locale-coding-system: utf-8-unix From debbugs-submit-bounces@debbugs.gnu.org Fri Aug 20 09:58:19 2021 Received: (at 50126) by debbugs.gnu.org; 20 Aug 2021 13:58:19 +0000 Received: from localhost ([127.0.0.1]:35173 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mH52J-0004nX-21 for submit@debbugs.gnu.org; Fri, 20 Aug 2021 09:58:19 -0400 Received: from quimby.gnus.org ([95.216.78.240]:60314) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mH52G-0004nG-Qs for 50126@debbugs.gnu.org; Fri, 20 Aug 2021 09:58:17 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=kdISjCtqI0lVc4APZqd54D+0qbULaP+AM5Y880AKyTA=; b=fkjTkL7X6jtgjJdnplr80g8HqL i98avpWHPF1G2V9aEGRVeioUlJbIxyDNuyei0sd8ekeeXAyqgJcZQLDu42U9GBmCPmu8sg1jhTk7g 0o3+nqGfC4esrlqnP221Dh+Nj3/VwP9QmnqaAZg4hxttoAlzX+bzRCo3ZJEOWevF7Dx8=; Received: from [84.212.220.105] (helo=elva) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mH525-0004dy-QI; Fri, 20 Aug 2021 15:58:10 +0200 From: Lars Ingebrigtsen To: Bob Rogers Subject: Re: bug#50126: 28.0.50; "mode: conf" and "mode: tex" get unbounded recursion References: <24862.37073.150567.609831@orion.rgrjr.com> Date: Fri, 20 Aug 2021 15:58:05 +0200 In-Reply-To: <24862.37073.150567.609831@orion.rgrjr.com> (Bob Rogers's message of "Thu, 19 Aug 2021 13:11:45 -0400") Message-ID: <874kbk8bgy.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Bob Rogers writes: > It fails with conf-unix-mode in the simple case of the configuration > file above; unsurprisingly, I've also seen it fail with conf-space-mode. > And "mode: tex; " has the same general problem, since [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 50126 Cc: 50126@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Bob Rogers writes: > It fails with conf-unix-mode in the simple case of the configuration > file above; unsurprisingly, I've also seen it fail with conf-space-mode. > And "mode: tex;" has the same general problem, since it uses the same > dispatch logic. Yeah, that's pretty odd dispatch logic, but I guess it's for historical reasons. The easy way to hack around this issue is to just disable recursion via file-local variables, so I've done that now in Emacs 28. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Fri Aug 20 09:58:24 2021 Received: (at control) by debbugs.gnu.org; 20 Aug 2021 13:58:24 +0000 Received: from localhost ([127.0.0.1]:35176 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mH52N-0004nm-8p for submit@debbugs.gnu.org; Fri, 20 Aug 2021 09:58:23 -0400 Received: from quimby.gnus.org ([95.216.78.240]:60328) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mH52L-0004nO-OR for control@debbugs.gnu.org; Fri, 20 Aug 2021 09:58:21 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Subject:From:To:Message-Id:Date:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=M5cXIZ2lto/Sj91j3hQ2P1iPXLzpvbxgH5bcNshEem0=; b=qaRqmoZ6QjlxYrJxSTfmPN5psf 8CtNAFmdtnBozETc7A7FWCw5bVGV9EDLDfgUEG6l8SFndHPlj3s3Qhz6h1TicCRk0TIUTl7PEAzxM dfGA2YWVSSisaRUXu7QFvNyo6mMvwhRg69jo1S6Lypnkbgq+1ZnIz8RAAbCXa0DSfp34=; Received: from [84.212.220.105] (helo=elva) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mH52D-0004e6-SN for control@debbugs.gnu.org; Fri, 20 Aug 2021 15:58:15 +0200 Date: Fri, 20 Aug 2021 15:58:13 +0200 Message-Id: <8735r48bgq.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #50126 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: close 50126 28.1 quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) close 50126 28.1 quit From unknown Sun Jun 22 22:42:38 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sat, 18 Sep 2021 11:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator