From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.help Subject: Re: emacs 24.4.1, gud-gdb, problem: at breakpoint hit, *gud* buffer is replaced with source code buffer Date: Wed, 18 Feb 2015 17:45:36 +0200 Message-ID: <838ufv5ilb.fsf@gnu.org> References: NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1424274363 21464 80.91.229.3 (18 Feb 2015 15:46:03 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 18 Feb 2015 15:46:03 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Feb 18 16:45:53 2015 Return-path: Envelope-to: geh-help-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 1YO6oy-0004Nt-77 for geh-help-gnu-emacs@m.gmane.org; Wed, 18 Feb 2015 16:45:52 +0100 Original-Received: from localhost ([::1]:51552 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YO6ox-0005wA-JC for geh-help-gnu-emacs@m.gmane.org; Wed, 18 Feb 2015 10:45:51 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:37514) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YO6oc-0005vN-3F for help-gnu-emacs@gnu.org; Wed, 18 Feb 2015 10:45:31 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YO6oY-00026P-MV for help-gnu-emacs@gnu.org; Wed, 18 Feb 2015 10:45:30 -0500 Original-Received: from mtaout21.012.net.il ([80.179.55.169]:46435) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YO6oY-00025W-Ey for help-gnu-emacs@gnu.org; Wed, 18 Feb 2015 10:45:26 -0500 Original-Received: from conversion-daemon.a-mtaout21.012.net.il by a-mtaout21.012.net.il (HyperSendmail v2007.08) id <0NJZ00200537SP00@a-mtaout21.012.net.il> for help-gnu-emacs@gnu.org; Wed, 18 Feb 2015 17:45:24 +0200 (IST) Original-Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout21.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0NJZ002K153OPD70@a-mtaout21.012.net.il> for help-gnu-emacs@gnu.org; Wed, 18 Feb 2015 17:45:24 +0200 (IST) In-reply-to: X-012-Sender: halo1@inter.net.il X-detected-operating-system: by eggs.gnu.org: Solaris 10 X-Received-From: 80.179.55.169 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:102792 Archived-At: > Date: Wed, 18 Feb 2015 16:08:21 +0100 > From: Paul K > > I'm trying to isolate the problem: > > 1) prompt$ emacs -q #. way I run emacs > 2) I visit directory that contains binary I want to debug. It is on remote > linux box (so emacs uses tramp to open it). > 2) M-x gud-gdb. > 3) I set two breakpoints. Each of them is in different C++ source file. > 4) I split my emacs frame into two windows. Upper window contains > *gud-proc* buffer. Lower window contains source file that contains second > breakpoint. > 5) I start program > 6) First breakpoint is hit. > Crazy thing: emacs splits upper window into two windows, this time > veritcally. Upper left window contains *gud-proc*, while upper right > contains source file with first breakpoint. > > I'd expect lower window should display the source file that contains > first breakpoint instead. No new window should be created by emacs. > > Am I wrong? Emacs does not generally reserve windows for buffers. If you invoke "M-x gdb" instead, and then "M-x gdb-many-windows" (or select GDB-MU->Display Other Windows from the menu bar), Emacs will try to keep each window dedicated to its buffer, because this is what that GDB interface was programmed to do. If you cannot use "M-x gdb", then please report this as a bug using "M-x report-emacs-bug", and perhaps someone will help you to find some fix or customization for this situation. > Even worse case happens when I prevent emacs from vertical split with > following setting: > (setq split-width-threshold nil) > > Then, at step 6 above, no new window is created, but instead, *gud-proc* > buffer, that is dislayed in upper window is replaced with source file that > keeps the first breakpoint. > > Maybe these two problems have the same root cause. Yes, see above.