From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14751 invoked by alias); 25 Apr 2011 16:05:05 -0000 Received: (qmail 14737 invoked by uid 22791); 25 Apr 2011 16:05:04 -0000 X-SWARE-Spam-Status: No, hits=-6.3 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,SPF_HELO_PASS,TW_KB,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 25 Apr 2011 16:04:49 +0000 Received: from int-mx12.intmail.prod.int.phx2.redhat.com (int-mx12.intmail.prod.int.phx2.redhat.com [10.5.11.25]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p3PG4k1e024494 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Mon, 25 Apr 2011 12:04:46 -0400 Received: from host1.jankratochvil.net (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx12.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id p3PG4ixU032297 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 25 Apr 2011 12:04:46 -0400 Received: from host1.jankratochvil.net (localhost [127.0.0.1]) by host1.jankratochvil.net (8.14.4/8.14.4) with ESMTP id p3PG4i6r025949; Mon, 25 Apr 2011 18:04:44 +0200 Received: (from jkratoch@localhost) by host1.jankratochvil.net (8.14.4/8.14.4/Submit) id p3PG4hxe025948; Mon, 25 Apr 2011 18:04:43 +0200 Date: Mon, 25 Apr 2011 16:05:00 -0000 From: Jan Kratochvil To: Eli Zaretskii Cc: tromey@redhat.com, gdb@sourceware.org, ktietz@redhat.com Subject: Re: readline rebase 5.1->6.2? Message-ID: <20110425160443.GA25761@host1.jankratochvil.net> References: <20110322154327.GA8966@host1.jankratochvil.net> <83tyev7z7a.fsf@gnu.org> <20110322194836.GA23104@host1.jankratochvil.net> <83oc537wrs.fsf@gnu.org> <83oc4qpbdw.fsf@gnu.org> <83y63tvtd2.fsf@gnu.org> <83sju0vy1k.fsf@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <83sju0vy1k.fsf@gnu.org> User-Agent: Mutt/1.5.21 (2010-09-15) X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2011-04/txt/msg00142.txt.bz2 On Sun, 03 Apr 2011 05:00:55 +0200, Eli Zaretskii wrote: > Note that I didn't do anything about the MinGW patches. I suggest > that their author(s) submit them to readline. The only one I found is attached, it is already present in readline-6.2-001. The configure.in part `*-mingw*)' is also present there. Therefore I believe we can now rebase readline to 6.2-001 for gdb-7.4, I will send some patch for test into gdb-patches. Thanks, Jan --- readline-5.1-004/input.c 2005-07-05 04:30:24.000000000 +0200 +++ ./input.c 2011-04-02 10:43:16.000000000 +0200 @@ -220,6 +220,16 @@ rl_gather_tyi () } #endif /* O_NDELAY */ +#if defined (__MINGW32__) + /* We use getch to read console input, so use the same + mechanism to check for more. Otherwise, we don't know. */ + if (isatty (fileno (rl_instream))) + chars_avail = _kbhit (); + else + chars_avail = 0; + result = 0; +#endif + /* If there's nothing available, don't waste time trying to read something. */ if (chars_avail <= 0) @@ -305,6 +315,13 @@ _rl_input_available () #endif +#if defined (__MINGW32__) + /* We use getch to read console input, so use the same + mechanism to check for more. Otherwise, we don't know. */ + if (isatty (fileno (rl_instream))) + return _kbhit (); +#endif + return 0; }