From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Glenn Morris Newsgroups: gmane.emacs.bugs Subject: bug#13066: 24.2.90; setting rmail-summary-window-size causes error Date: Thu, 06 Dec 2012 15:55:07 -0500 Message-ID: References: <87fw3jjua1.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1354827352 24456 80.91.229.3 (6 Dec 2012 20:55:52 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 6 Dec 2012 20:55:52 +0000 (UTC) Cc: 13066@debbugs.gnu.org To: Kenichi Handa Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Dec 06 21:56:05 2012 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1TgiUG-0006XH-F6 for geb-bug-gnu-emacs@m.gmane.org; Thu, 06 Dec 2012 21:56:04 +0100 Original-Received: from localhost ([::1]:47511 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TgiU4-00059r-CW for geb-bug-gnu-emacs@m.gmane.org; Thu, 06 Dec 2012 15:55:52 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:44818) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TgiU1-00059l-GT for bug-gnu-emacs@gnu.org; Thu, 06 Dec 2012 15:55:51 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TgiU0-0000oi-EF for bug-gnu-emacs@gnu.org; Thu, 06 Dec 2012 15:55:49 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:47061) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TgiU0-0000oc-8O for bug-gnu-emacs@gnu.org; Thu, 06 Dec 2012 15:55:48 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1TgiUE-00015u-DS for bug-gnu-emacs@gnu.org; Thu, 06 Dec 2012 15:56:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Glenn Morris Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 06 Dec 2012 20:56:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13066 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 13066-submit@debbugs.gnu.org id=B13066.13548273314169 (code B ref 13066); Thu, 06 Dec 2012 20:56:02 +0000 Original-Received: (at 13066) by debbugs.gnu.org; 6 Dec 2012 20:55:31 +0000 Original-Received: from localhost ([127.0.0.1]:57312 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TgiTf-000159-Kf for submit@debbugs.gnu.org; Thu, 06 Dec 2012 15:55:28 -0500 Original-Received: from fencepost.gnu.org ([208.118.235.10]:52140) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TgiTd-000152-4p for 13066@debbugs.gnu.org; Thu, 06 Dec 2012 15:55:26 -0500 Original-Received: from rgm by fencepost.gnu.org with local (Exim 4.71) (envelope-from ) id 1TgiTL-0006er-UL; Thu, 06 Dec 2012 15:55:07 -0500 X-Spook: NWO SWAT embassy basement number key pipeline FBI Al-Qaeda X-Ran: zW8;qZ):/A;0k)+r^i]LOO%mZN_,*~7;=k*K?1dX06d (Kenichi Handa's message of "Thu, 06 Dec 2012 20:26:46 +0900") User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:68059 Archived-At: Kenichi Handa wrote: > % emacs -Q > M-x rmail RET > M-x customize-variable RET rmail-summary-window-size > ;; Then set it to 10, click [apply], type q, then type h, > ;; and then type g (rmail-summary-get-new-mail). > > This causes the same error. The backtrace is this: > > Debugger entered--Lisp error: (wrong-type-argument numberp nil) > zerop(nil) > (or (zerop msg) (rmail-summary-goto-msg msg)) > (let (msg) (save-current-buffer (set-buffer rmail-buffer) (rmail-get-new-mail file-name) (setq msg rmail-current-message)) (or (zerop msg) (rmail-summary-goto-msg msg))) > rmail-summary-get-new-mail(nil) > call-interactively(rmail-summary-get-new-mail nil nil) This is also because rmail-maybe-display-summary behaves differently to how it used to. When we enter rmail-maybe-display-summary: current-buffer = RMAIL selected-window = RMAIL summary When we get to the end of this function: (unwind-protect (progn ;; current-buffer = RMAIL (select-window window) ; -> RMAIL summary ;; In 24.2, RMAIL buffer still current. ;; In 24.2.90, RMAIL summary buffer is now current. (enlarge-window (- rmail-summary-window-size (window-height)))) (select-window selected))))) I think we could summarize the difference between 24.2 and 24.2.90 by using emacs -Q, then evaluating the following in scratch: (progn (message "1 : %s : %s" (current-buffer) (selected-window)) (set-buffer "*Messages*") (message "2 : %s : %s" (current-buffer) (setq window (selected-window))) (select-window window) (message "3 : %s : %s" (current-buffer) (setq window (selected-window)))) With 24.2, the result is: 1 : *scratch* : # 2 : *Messages* : # 3 : *Messages* : # With 24.2.90, it is: 1 : *scratch* : # 2 : *Messages* : # 3 : *scratch* : #