From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#9767: 24.0.90; gdb initialization on Cygwin Date: Mon, 17 Oct 2011 01:39:19 -0400 Message-ID: References: <4E9B0033.2070506@cornell.edu> <4E9B63F0.5040409@cornell.edu> Reply-To: Eli Zaretskii NNTP-Posting-Host: lo.gmane.org X-Trace: dough.gmane.org 1318830030 27693 80.91.229.12 (17 Oct 2011 05:40:30 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 17 Oct 2011 05:40:30 +0000 (UTC) Cc: 9767@debbugs.gnu.org To: Ken Brown Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Oct 17 07:40:26 2011 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RFfw2-0000ZQ-E0 for geb-bug-gnu-emacs@m.gmane.org; Mon, 17 Oct 2011 07:40:26 +0200 Original-Received: from localhost ([::1]:46499 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RFfw1-0004lt-L4 for geb-bug-gnu-emacs@m.gmane.org; Mon, 17 Oct 2011 01:40:25 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:41782) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RFfvu-0004lk-Fx for bug-gnu-emacs@gnu.org; Mon, 17 Oct 2011 01:40:23 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RFfvp-0005ri-Fm for bug-gnu-emacs@gnu.org; Mon, 17 Oct 2011 01:40:18 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:55332) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RFfvp-0005re-6n for bug-gnu-emacs@gnu.org; Mon, 17 Oct 2011 01:40:13 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1RFfwc-0002iJ-BB for bug-gnu-emacs@gnu.org; Mon, 17 Oct 2011 01:41:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 17 Oct 2011 05:41:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 9767 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 9767-submit@debbugs.gnu.org id=B9767.131883001210371 (code B ref 9767); Mon, 17 Oct 2011 05:41:02 +0000 Original-Received: (at 9767) by debbugs.gnu.org; 17 Oct 2011 05:40:12 +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 1RFfvn-0002hC-U7 for submit@debbugs.gnu.org; Mon, 17 Oct 2011 01:40:12 -0400 Original-Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RFfvm-0002h5-3O for 9767@debbugs.gnu.org; Mon, 17 Oct 2011 01:40:11 -0400 Original-Received: from eliz by fencepost.gnu.org with local (Exim 4.71) (envelope-from ) id 1RFfux-0003wt-EL; Mon, 17 Oct 2011 01:39:19 -0400 In-reply-to: <4E9B63F0.5040409@cornell.edu> (message from Ken Brown on Sun, 16 Oct 2011 19:08:32 -0400) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Mon, 17 Oct 2011 01:41:02 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) 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:52705 Archived-At: > Date: Sun, 16 Oct 2011 19:08:32 -0400 > From: Ken Brown > > Further info: It seems that initialization is actually completing, but > for some reason the buffer is not being redisplayed. To test this, I > inserted (sit-for .1) at the end of gdb-update to force redisplay, and > that solved the problem. Unless someone who understands redisplay can > figure out why redisplay isn't happening on Cygwin, I'm inclined to > apply the following patch: My crystal ball says that redisplay isn't happening because Emacs doesn't know that the GDB prompt has arrived. The call to sit-for causes Emacs to check its input descriptors, "discovering" that there is input. Please look around in wait_reading_process_output, and see what is going on there, before and after the call to sit-for. In particular, does the call to `select' report that input has arrived from GDB? > === modified file 'lisp/progmodes/gdb-mi.el' > --- lisp/progmodes/gdb-mi.el 2011-10-06 16:11:38 +0000 > +++ lisp/progmodes/gdb-mi.el 2011-10-16 23:04:28 +0000 > @@ -1726,7 +1726,8 @@ > (gdb-force-mode-line-update > (propertize "initializing..." 'face font-lock-variable-name-face)) > (gdb-init-1) > - (setq gdb-first-prompt nil)) > + (setq gdb-first-prompt nil) > + (if (eq system-type 'cygwin) (sit-for .1))) > > (gdb-get-main-selected-frame) > ;; We may need to update gdb-threads-list so we can use > > Would this be reasonable? I think it's not going to solve the real problem. If Emacs misses some of the output arriving from GDB, it will miss it again under similar circumstances.