From unknown Fri Jun 20 07:10:11 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#818 <818@debbugs.gnu.org> To: bug#818 <818@debbugs.gnu.org> Subject: Status: 23.0.60; error when window-size-change-functions is a buffer-local hook Reply-To: bug#818 <818@debbugs.gnu.org> Date: Fri, 20 Jun 2025 14:10:11 +0000 retitle 818 23.0.60; error when window-size-change-functions is a buffer-lo= cal hook reassign 818 emacs submitter 818 Markus Triska severity 818 normal thanks From markus.triska@gmx.at Fri Aug 29 08:05:07 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-6.9 required=4.0 tests=AWL,BAYES_00,FOURLA, RCVD_IN_DNSWL_MED autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at submit) by emacsbugs.donarmstrong.com; 29 Aug 2008 15:05:08 +0000 Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m7TF4xSQ016787 for ; Fri, 29 Aug 2008 08:05:00 -0700 Received: from mx10.gnu.org ([199.232.76.166]:53456) by fencepost.gnu.org with esmtp (Exim 4.67) (envelope-from ) id 1KZ5VX-0003HU-Cp for emacs-pretest-bug@gnu.org; Fri, 29 Aug 2008 11:03:27 -0400 Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1KZ5WB-00083A-OX for emacs-pretest-bug@gnu.org; Fri, 29 Aug 2008 11:04:10 -0400 Received: from mail.gmx.net ([213.165.64.20]:57799) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1KZ5WB-00082e-7u for emacs-pretest-bug@gnu.org; Fri, 29 Aug 2008 11:04:07 -0400 Received: (qmail invoked by alias); 29 Aug 2008 15:04:04 -0000 Received: from v254-244.vps.tuwien.ac.at (EHLO v254-244.vps.tuwien.ac.at) [128.131.254.244] by mail.gmx.net (mp025) with SMTP; 29 Aug 2008 17:04:04 +0200 X-Authenticated: #4064391 X-Provags-ID: V01U2FsdGVkX18mx+wYE9Qm/17fgWr8us0rl7Bq4/eoF2who/5ABS nrVVfdQFhTmdaX Received: by v254-004.vps.tuwien.ac.at (Postfix, from userid 502) id A6AB7A4506F; Fri, 29 Aug 2008 11:03:45 -0400 (EDT) From: Markus Triska To: emacs-pretest-bug@gnu.org Subject: 23.0.60; error when window-size-change-functions is a buffer-local hook Date: Fri, 29 Aug 2008 11:03:45 -0400 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Y-GMX-Trusted: 0 X-FuHaFi: 0.54 X-detected-kernel: by monty-python.gnu.org: Genre and OS details not recognized. In "emacs -Q", evaluating: (progn (add-hook 'window-size-change-functions 'identity nil t) (split-window)) yields: Symbol's function definition is void: t In GNU Emacs 23.0.60.4 (i386-apple-darwin8.11.1, GTK+ Version 2.12.9) of 2008-08-26 on mt-computer.vdn.ca Windowing system distributor `The XFree86 Project, Inc', version 11.0.40400000 Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: en.UTF-8 value of $XMODIFIERS: nil locale-coding-system: nil default-enable-multibyte-characters: t From rudalics@gmx.at Sat Aug 30 07:25:00 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-6.0 required=4.0 tests=AWL,BAYES_00,FOURLA, HAS_BUG_NUMBER,MIXEDBDN,MURPHY_DRUGS_REL8 autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at 818) by emacsbugs.donarmstrong.com; 30 Aug 2008 14:25:00 +0000 Received: from mail.gmx.net (mail.gmx.net [213.165.64.20]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with SMTP id m7UEOucR003371 for <818@emacsbugs.donarmstrong.com>; Sat, 30 Aug 2008 07:24:57 -0700 Received: (qmail invoked by alias); 30 Aug 2008 14:24:50 -0000 Received: from 62-47-52-54.adsl.highway.telekom.at (EHLO [62.47.52.54]) [62.47.52.54] by mail.gmx.net (mp042) with SMTP; 30 Aug 2008 16:24:50 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX18+T1oHOTs+P5ikPuEK0JF24U4iNiv618ka+6mwVF b84oMmY1ILPhBB Message-ID: <48B95651.4010305@gmx.at> Date: Sat, 30 Aug 2008 16:16:49 +0200 From: martin rudalics User-Agent: Thunderbird 2.0.0.16 (Windows/20080708) MIME-Version: 1.0 To: Markus Triska , 818@debbugs.gnu.org Subject: Re: bug#818: 23.0.60; error when window-size-change-functions is a buffer-local hook References: In-Reply-To: Content-Type: multipart/mixed; boundary="------------020903060601040201050600" X-Y-GMX-Trusted: 0 X-FuHaFi: 0.75,0.6 This is a multi-part message in MIME format. --------------020903060601040201050600 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit > In "emacs -Q", evaluating: > > (progn > (add-hook 'window-size-change-functions 'identity nil t) > (split-window)) > > yields: > > Symbol's function definition is void: t Does the attached patch fix it? martin --------------020903060601040201050600 Content-Type: text/plain; name="818.diff" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="818.diff" *** xdisp.c.~1.1244.~ 2008-08-07 03:54:06.000000000 +0200 --- xdisp.c 2008-08-30 16:12:09.765625000 +0200 *************** *** 9591,9597 **** while (CONSP (functions)) { ! call1 (XCAR (functions), frame); functions = XCDR (functions); } UNGCPRO; --- 9591,9598 ---- while (CONSP (functions)) { ! if (!EQ (XCAR (functions), Qt)) ! call1 (XCAR (functions), frame); functions = XCDR (functions); } UNGCPRO; --------------020903060601040201050600-- From markus.triska@gmx.at Sat Aug 30 22:50:10 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-6.1 required=4.0 tests=AWL,BAYES_00,FVGT_m_MULTI_ODD, HAS_BUG_NUMBER,IMPRONONCABLE_2,MURPHY_DRUGS_REL8 autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at 818) by emacsbugs.donarmstrong.com; 31 Aug 2008 05:50:10 +0000 Received: from mail.gmx.net (mail.gmx.net [213.165.64.20]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with SMTP id m7V5o5Wi023920 for <818@emacsbugs.donarmstrong.com>; Sat, 30 Aug 2008 22:50:07 -0700 Received: (qmail invoked by alias); 31 Aug 2008 05:49:59 -0000 Received: from v254-019.vps.tuwien.ac.at (EHLO v254-019.vps.tuwien.ac.at) [128.131.254.19] by mail.gmx.net (mp021) with SMTP; 31 Aug 2008 07:49:59 +0200 X-Authenticated: #4064391 X-Provags-ID: V01U2FsdGVkX18UmxhK0vUUP/5iYONxFQwuvNvXIdSWZSiQxyJe/f EQV94MCe9WcQos Received: by mt-computer.local (Postfix, from userid 502) id 3E3C3A467FB; Sun, 31 Aug 2008 01:49:38 -0400 (EDT) From: Markus Triska To: martin rudalics Cc: 818@debbugs.gnu.org Subject: Re: bug#818: 23.0.60; error when window-size-change-functions is a buffer-local hook References: <48B95651.4010305@gmx.at> Date: Sun, 31 Aug 2008 01:49:37 -0400 In-Reply-To: <48B95651.4010305@gmx.at> (martin rudalics's message of "Sat, 30 Aug 2008 16:16:49 +0200") Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Y-GMX-Trusted: 0 X-FuHaFi: 0.54 martin rudalics writes: > Does the attached patch fix it? Yes, thank you. Once it is fixed in trunk, could you please apply the following patch to linum.el? Thank you! 2008-08-30 Markus Triska * linum.el (linum-mode): `window-size-change-functions' can now be buffer-local. (linum-update-window): Use result of `move-overlay'. diff --git a/lisp/linum.el b/lisp/linum.el index a88bb61..4f77035 100644 --- a/lisp/linum.el +++ b/lisp/linum.el @@ -30,7 +30,7 @@ ;;; Code: -(defconst linum-version "0.9wz") +(defconst linum-version "0.9x") (defvar linum-overlays nil "Overlays used in this buffer.") (defvar linum-available nil "Overlays available for reuse.") @@ -82,15 +82,14 @@ and you have to scroll or press \\[recenter-top-bottom] to update the numbers." 'linum-update-current) nil t) (add-hook 'after-change-functions 'linum-after-change nil t)) (add-hook 'window-scroll-functions 'linum-after-scroll nil t) - ;; mistake in Emacs: window-size-change-functions cannot be local - (add-hook 'window-size-change-functions 'linum-after-size) + (add-hook 'window-size-change-functions 'linum-after-size nil t) (add-hook 'change-major-mode-hook 'linum-delete-overlays nil t) (add-hook 'window-configuration-change-hook 'linum-after-config nil t) (linum-update-current)) (remove-hook 'post-command-hook 'linum-update-current t) (remove-hook 'post-command-hook 'linum-schedule t) - (remove-hook 'window-size-change-functions 'linum-after-size) + (remove-hook 'window-size-change-functions 'linum-after-size t) (remove-hook 'window-scroll-functions 'linum-after-scroll t) (remove-hook 'after-change-functions 'linum-after-change t) (remove-hook 'window-configuration-change-hook 'linum-after-config t) @@ -154,11 +153,9 @@ and you have to scroll or press \\[recenter-top-bottom] to update the numbers." (throw 'visited t)))))) (setq width (max width (length str))) (unless visited - (let (ov) - (if (null linum-available) - (setq ov (make-overlay (point) (point))) - (setq ov (pop linum-available)) - (move-overlay ov (point) (point))) + (let ((ov (if (null linum-available) + (make-overlay (point) (point)) + (move-overlay (pop linum-available) (point) (point))))) (push ov linum-overlays) (overlay-put ov 'before-string (propertize " " 'display `((margin left-margin) ,str))) From rudalics@gmx.at Sun Aug 31 02:03:35 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-6.5 required=4.0 tests=AWL,BAYES_00,FOURLA, HAS_BUG_NUMBER,MURPHY_DRUGS_REL8 autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at 818) by emacsbugs.donarmstrong.com; 31 Aug 2008 09:03:35 +0000 Received: from mail.gmx.net (mail.gmx.net [213.165.64.20]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with SMTP id m7V93Ue3024555 for <818@emacsbugs.donarmstrong.com>; Sun, 31 Aug 2008 02:03:32 -0700 Received: (qmail invoked by alias); 31 Aug 2008 09:03:24 -0000 Received: from 62-47-51-29.adsl.highway.telekom.at (EHLO [62.47.51.29]) [62.47.51.29] by mail.gmx.net (mp068) with SMTP; 31 Aug 2008 11:03:24 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX18AIy10624AAxyhsNe9n3rkwMhWydIanLggmHARbO tTULWK8cmaHov4 Message-ID: <48BA5DC2.2090108@gmx.at> Date: Sun, 31 Aug 2008 11:00:50 +0200 From: martin rudalics User-Agent: Thunderbird 2.0.0.16 (Windows/20080708) MIME-Version: 1.0 To: Markus Triska CC: 818@debbugs.gnu.org Subject: Re: bug#818: 23.0.60; error when window-size-change-functions is a buffer-local hook References: <48B95651.4010305@gmx.at> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-FuHaFi: 0.7 >> Does the attached patch fix it? > > Yes, thank you. Once it is fixed in trunk, could you please apply the > following patch to linum.el? Thank you! I hopefully checked it in. Please have a look. > + (add-hook 'window-size-change-functions 'linum-after-size nil t) My fix only makes sure that Emacs does not issue an error when calling a function in `window-size-change-functions' and one of these functions was earlier added buffer-locally. But I'm not sure whether this DTRT when the value is buffer-local. If it doesn't, we might have to fix it as Stefan did for `window-configuration-change-hook' just with the frame argument added. Please have a look at this issue. You might also want to look at the thread "Wrong window end reported after splitting window" on emacs-devel around the beginning of this year. martin From schwab@suse.de Mon Sep 1 01:58:09 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-10.1 required=4.0 tests=AWL,BAYES_00,FOURLA, HAS_BUG_NUMBER,RCVD_IN_DNSWL_MED autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at 818) by emacsbugs.donarmstrong.com; 1 Sep 2008 08:58:09 +0000 Received: from mx2.suse.de (cantor2.suse.de [195.135.220.15]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m818w5B0025323 for <818@emacsbugs.donarmstrong.com>; Mon, 1 Sep 2008 01:58:07 -0700 Received: from Relay2.suse.de (mail2.suse.de [195.135.221.8]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx2.suse.de (Postfix) with ESMTP id 962E445FEA; Mon, 1 Sep 2008 10:58:04 +0200 (CEST) From: Andreas Schwab To: martin rudalics Cc: 818@debbugs.gnu.org, Markus Triska Subject: Re: bug#818: 23.0.60; error when window-size-change-functions is a buffer-local hook References: <48B95651.4010305@gmx.at> X-Yow: BRYLCREAM is CREAM O' WHEAT in another DIMENSION.. Date: Mon, 01 Sep 2008 10:58:03 +0200 In-Reply-To: <48B95651.4010305@gmx.at> (martin rudalics's message of "Sat, 30 Aug 2008 16:16:49 +0200") Message-ID: User-Agent: Gnus/5.110009 (No Gnus v0.9) Emacs/22.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit martin rudalics writes: > *** xdisp.c.~1.1244.~ 2008-08-07 03:54:06.000000000 +0200 > --- xdisp.c 2008-08-30 16:12:09.765625000 +0200 > *************** > *** 9591,9597 **** > > while (CONSP (functions)) > { > ! call1 (XCAR (functions), frame); > functions = XCDR (functions); > } > UNGCPRO; > --- 9591,9598 ---- > > while (CONSP (functions)) > { > ! if (!EQ (XCAR (functions), Qt)) > ! call1 (XCAR (functions), frame); > functions = XCDR (functions); > } > UNGCPRO; Why doesn't this use run-hook-with-args? Andreas. -- Andreas Schwab, SuSE Labs, schwab@suse.de SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany PGP key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5 "And now for something completely different." From rudalics@gmx.at Mon Sep 1 02:18:17 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-6.6 required=4.0 tests=AWL,BAYES_00,HAS_BUG_NUMBER autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at 818) by emacsbugs.donarmstrong.com; 1 Sep 2008 09:18:17 +0000 Received: from mail.gmx.net (mail.gmx.net [213.165.64.20]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with SMTP id m819IDNg032581 for <818@emacsbugs.donarmstrong.com>; Mon, 1 Sep 2008 02:18:14 -0700 Received: (qmail invoked by alias); 01 Sep 2008 09:18:07 -0000 Received: from 62-47-51-225.adsl.highway.telekom.at (EHLO [62.47.51.225]) [62.47.51.225] by mail.gmx.net (mp022) with SMTP; 01 Sep 2008 11:18:07 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX1/60HJquvL6+If1o4/HY6+B6PTlr9xtCfQ+/FSboh Utfv+rABx7v6iR Message-ID: <48BBB29A.3040402@gmx.at> Date: Mon, 01 Sep 2008 11:15:06 +0200 From: martin rudalics User-Agent: Thunderbird 2.0.0.16 (Windows/20080708) MIME-Version: 1.0 To: Andreas Schwab CC: 818@debbugs.gnu.org, Markus Triska Subject: Re: bug#818: 23.0.60; error when window-size-change-functions is a buffer-local hook References: <48B95651.4010305@gmx.at> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-FuHaFi: 0.83 > Why doesn't this use run-hook-with-args? I don't know. The recent run_funs in window.c uses call0. Please do whatever you consider appropriate. Thanks, martin. From cyd@stupidchicken.com Mon Sep 1 12:49:26 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-3.7 required=4.0 tests=AWL,BAYES_00 autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at control) by emacsbugs.donarmstrong.com; 1 Sep 2008 19:49:26 +0000 Received: from cyd.mit.edu (CYD.MIT.EDU [18.115.2.24]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m81JnNIf020361 for ; Mon, 1 Sep 2008 12:49:24 -0700 Received: by cyd.mit.edu (Postfix, from userid 1000) id F354557E337; Mon, 1 Sep 2008 15:51:39 -0400 (EDT) To: control@debbugs.gnu.org Subject: close 818 From: Chong Yidong Date: Mon, 01 Sep 2008 15:51:39 -0400 Message-ID: <87aberfxv8.fsf@cyd.mit.edu> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii close 818 thanks From unknown Fri Jun 20 07:10:11 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: $requester Subject: Internal Control Message-Id: bug archived. Date: Tue, 30 Sep 2008 14:24:03 +0000 User-Agent: Fakemail v42.6.9 # A New Hope # A log time ago, in a galaxy far, far away # something happened. # # Magically this resulted in the following # action being taken, but this fake control # message doesn't tell you why it happened # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator