From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.bugs,gmane.emacs.pretest.bugs Subject: bug#670: bug#1077: 23.0.60; x-create-frame: (wrong-type-argument number-or-marker-p nil) Date: Fri, 26 Nov 2010 18:52:09 -0800 Message-ID: <96BC00F728B94AC18A15EA95B66C5248@us.oracle.com> References: <003e01c9257c$a385d800$0200a8c0@us.oracle.com><009701c9263f$9cce7120$0200a8c0@us.oracle.com><000001c94cc1$e10e9c40$0200a8c0@us.oracle.com> <8F1F8998D60341099C4204B7BDD8AD4F@us.oracle.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1290827715 17410 80.91.229.12 (27 Nov 2010 03:15:15 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sat, 27 Nov 2010 03:15:15 +0000 (UTC) To: <1077@debbugs.gnu.org>, <1077@emacsbugs.donarmstrong.com>, , <670@emacsbugs.donarmstrong.com> Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Nov 27 04:15:07 2010 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PMBFh-0005om-BV for geb-bug-gnu-emacs@m.gmane.org; Sat, 27 Nov 2010 04:15:06 +0100 Original-Received: from localhost ([127.0.0.1]:58240 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PMBFg-0001pB-2I for geb-bug-gnu-emacs@m.gmane.org; Fri, 26 Nov 2010 22:15:04 -0500 Original-Received: from [140.186.70.92] (port=38714 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PMBFW-0001nE-3N for bug-gnu-emacs@gnu.org; Fri, 26 Nov 2010 22:14:56 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PMBFU-0005U2-6Y for bug-gnu-emacs@gnu.org; Fri, 26 Nov 2010 22:14:53 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:58987) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PMBFU-0005Tx-4m for bug-gnu-emacs@gnu.org; Fri, 26 Nov 2010 22:14:52 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1PMAoa-0007zV-14; Fri, 26 Nov 2010 21:47:04 -0500 X-Loop: help-debbugs@gnu.org Resent-From: "Drew Adams" Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 27 Nov 2010 02:47:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 670 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: moreinfo Original-Received: via spool by 670-submit@debbugs.gnu.org id=B670.129082601530671 (code B ref 670); Sat, 27 Nov 2010 02:47:03 +0000 Original-Received: (at 670) by debbugs.gnu.org; 27 Nov 2010 02:46:55 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PMAoN-0007yc-9z for submit@debbugs.gnu.org; Fri, 26 Nov 2010 21:46:51 -0500 Original-Received: from rcsinet10.oracle.com ([148.87.113.121]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PMAoL-0007yK-EE; Fri, 26 Nov 2010 21:46:50 -0500 Original-Received: from rcsinet13.oracle.com (rcsinet13.oracle.com [148.87.113.125]) by rcsinet10.oracle.com (Switch-3.4.2/Switch-3.4.2) with ESMTP id oAR2qEnZ014381 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Sat, 27 Nov 2010 02:52:15 GMT Original-Received: from acsmt353.oracle.com (acsmt353.oracle.com [141.146.40.153]) by rcsinet13.oracle.com (Switch-3.4.2/Switch-3.4.1) with ESMTP id oAR2qDPv019308; Sat, 27 Nov 2010 02:52:14 GMT Original-Received: from abhmt020.oracle.com by acsmt355.oracle.com with ESMTP id 809076291290826321; Fri, 26 Nov 2010 18:52:01 -0800 Original-Received: from dradamslap1 (/10.159.220.70) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Fri, 26 Nov 2010 18:52:01 -0800 X-Mailer: Microsoft Office Outlook 11 In-Reply-To: <8F1F8998D60341099C4204B7BDD8AD4F@us.oracle.com> Thread-Index: AcklfKMogyzuwpKNQfi7bBVuuBtQ1gAwkUgQCaB5gbA+d9nMwFHOYZLw X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.5994 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Fri, 26 Nov 2010 21:47:04 -0500 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) 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: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:41911 gmane.emacs.pretest.bugs:25416 Archived-At: I am still seeing this systematically, including in the latest dev version, In GNU Emacs 24.0.50.1 (i386-mingw-nt5.1.2600) of 2010-11-22 on 3249CTO Windowing system distributor `Microsoft Corp.', version 5.1.2600 configured using `configure --with-gcc (4.4) --no-opt --cflags -Ic:/imagesupport/include' Below is a backtrace from this current version. One scenario that provokes the error: I have a standalone minibuffer frame. I bind a key in `completion-list-mode-map' during minibuffer completion to call `describe-function' on a command name candidate in *Completions* that is clicked with mouse-2. *Help*, like *Completions* is a special-display buffer that appears in its own frame. Input from *Completions* is redirected to the minibuffer. I do C-h f and get some candidates in *Completions*. I click one with mouse-2. *Help* shows its doc. I click the file-name link in *Help* to see the source library for the function. That's when I get the error. Same thing if I use a key bound in `minibuffer-must-match-map' and type a candidate then hit that key. Either way I see the function doc in *Help*, and when I click the file-name link I get the error. There are other ways to reproduce it. They all involve an action during minibuffer completion. Another clue, perhaps: I get this error when I do something in the minibuffer (invoke some function) that tries to create a frame. For example, if the *Help* frame doesn't already exist when I hit the key mentioned above to show the output from `describe-function' (for some completion candidate) in *Help*, then I get the error when it tries to create the *Help* frame. I tried to follow `display-buffer' in the debugger. I can't get further than the C-code call to x-create-frame. If you look at the date when I originally filed this bug you should be able to see when some change was made to the x-create-frame C-code that introduced this regression. At least you should be able to see some code in x-create-frame or called from it that tries to test (> SOMETHING1 SOMETHING2), which ends up calling (> nil 0), raising the error. I tried ediffing the Emacs 22.1 C code for x-create-frame against the current C code for it, but I couldn't guess anything (that single function definition alone is over 12,000 chars!). It's been this way since Emacs 23 (even pretests for 23). No one has tried to look into this. ----------------------- Debugger entered--Lisp error: (wrong-type-argument number-or-marker-p nil) >(nil 0) x-create-frame(((visibility) (tool-bar-lines . 0) (fringe . 0) (right-fringe . 0) (left-fringe . 0) (icon-type) (vertical-scroll-bars . right) (user-position . t) (minibuffer) (height . 35) (width . 80) (left . 0) (top . 0) (menu-bar-lines . 1) (cursor-type . bar))) x-create-frame-with-faces(((tool-bar-lines . 0) (fringe . 0) (right-fringe . 0) (left-fringe . 0) (icon-type) (vertical-scroll-bars . right) (user-position . t) (minibuffer) (height . 35) (width . 80) (left . 0) (top . 0) (menu-bar-lines . 1) (cursor-type . bar) (cursor-color . "Red") (mouse-color . "Red") (font . "-*-Lucida Console-normal-r-*-*-14-112-96-96-c-*-iso8859-1") (background-color . "LightBlue") (foreground-color . "Black"))) make-frame(nil) (lambda nil (make-frame pop-up-frame-alist))() funcall((lambda nil (make-frame pop-up-frame-alist))) (frame-selected-window (funcall pop-up-frame-function)) (let ((win (frame-selected-window (funcall pop-up-frame-function)))) (window--display-buffer-2 buffer win display-buffer-mark-dedicated)) (cond ((not (buffer-live-p buffer)) (error "No such buffer %s" buffer)) (display-buffer-function (funcall display-buffer-function buffer not-this-window)) ((and (not not-this-window) (eq (window-buffer (selected-window)) buffer)) (window--display-buffer-1 (selected-window))) ((and can-use-selected-window (same-window-p name-of-buffer)) (window--display-buffer-2 buffer (selected-window))) ((let ((frames (or frame (and (or use-pop-up-frames display-buffer-reuse-frames ...) 0) (last-nonminibuffer-frame)))) (setq window-to-use (catch (quote found) (dolist (window (get-buffer-window-list buffer ... frames)) (when (or can-use-selected-window ...) (throw ... window)))))) (window--display-buffer-1 window-to-use)) ((and special-display-function (let ((pars (special-display-p name-of-buffer))) (when pars (funcall special-display-function buffer (if (listp pars) pars)))))) ((or use-pop-up-frames (not frame-to-use)) (let ((win (frame-selected-window (funcall pop-up-frame-function)))) (window--display-buffer-2 buffer win display-buffer-mark-dedicated))) ((and pop-up-windows (or (not (frame-parameter frame-to-use (quote unsplittable))) (and (eq frame-to-use (selected-frame)) (setq frame-to-use (last-nonminibuffer-frame)) (window--frame-usable-p frame-to-use) (not (frame-parameter frame-to-use (quote unsplittable))))) (setq window-to-use (or (window--try-to-split-window (get-largest-window frame-to-use t)) (window--try-to-split-window (get-lru-window frame-to-use t))))) (window--display-buffer-2 buffer window-to-use display-buffer-mark-dedicated)) ((let ((window-to-undedicate (and not-this-window (not (window-dedicated-p)) (set-window-dedicated-p (selected-window) t) (selected-window)))) (unwind-protect (setq window-to-use (or (get-lru-window frame-to-use) (let (...) (unless ... window)) (get-largest-window (quote visible)) (let (...) (unless ... window)) (get-largest-window 0) (frame-selected-window (funcall pop-up-frame-function)))) (when (window-live-p window-to-undedicate) (set-window-dedicated-p window-to-undedicate nil)))) (window--even-window-heights window-to-use) (window--display-buffer-2 buffer window-to-use))) (let* ((can-use-selected-window (not (or not-this-window (window-dedicated-p (selected-window)) (window-minibuffer-p)))) (buffer (if (bufferp buffer-or-name) buffer-or-name (get-buffer buffer-or-name))) (name-of-buffer (buffer-name buffer)) (use-pop-up-frames (if (eq pop-up-frames (quote graphic-only)) (display-graphic-p) pop-up-frames)) (frame-to-use (or (window--frame-usable-p (selected-frame)) (window--frame-usable-p (last-nonminibuffer-frame)))) window-to-use) (cond ((not (buffer-live-p buffer)) (error "No such buffer %s" buffer)) (display-buffer-function (funcall display-buffer-function buffer not-this-window)) ((and (not not-this-window) (eq (window-buffer (selected-window)) buffer)) (window--display-buffer-1 (selected-window))) ((and can-use-selected-window (same-window-p name-of-buffer)) (window--display-buffer-2 buffer (selected-window))) ((let ((frames (or frame (and ... 0) (last-nonminibuffer-frame)))) (setq window-to-use (catch (quote found) (dolist (window ...) (when ... ...))))) (window--display-buffer-1 window-to-use)) ((and special-display-function (let ((pars (special-display-p name-of-buffer))) (when pars (funcall special-display-function buffer (if ... pars)))))) ((or use-pop-up-frames (not frame-to-use)) (let ((win (frame-selected-window (funcall pop-up-frame-function)))) (window--display-buffer-2 buffer win display-buffer-mark-dedicated))) ((and pop-up-windows (or (not (frame-parameter frame-to-use (quote unsplittable))) (and (eq frame-to-use (selected-frame)) (setq frame-to-use (last-nonminibuffer-frame)) (window--frame-usable-p frame-to-use) (not (frame-parameter frame-to-use ...)))) (setq window-to-use (or (window--try-to-split-window (get-largest-window frame-to-use t)) (window--try-to-split-window (get-lru-window frame-to-use t))))) (window--display-buffer-2 buffer window-to-use display-buffer-mark-dedicated)) ((let ((window-to-undedicate (and not-this-window (not ...) (set-window-dedicated-p ... t) (selected-window)))) (unwind-protect (setq window-to-use (or (get-lru-window frame-to-use) (let ... ...) (get-largest-window ...) (let ... ...) (get-largest-window 0) (frame-selected-window ...))) (when (window-live-p window-to-undedicate) (set-window-dedicated-p window-to-undedicate nil)))) (window--even-window-heights window-to-use) (window--display-buffer-2 buffer window-to-use)))) display-buffer(# nil) pop-to-buffer(#)