From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30279 invoked by alias); 8 May 2013 16:21:51 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 30265 invoked by uid 89); 8 May 2013 16:21:50 -0000 X-Spam-SWARE-Status: No, score=-8.4 required=5.0 tests=AWL,BAYES_00,KHOP_THREADED,RCVD_IN_HOSTKARMA_W,RCVD_IN_HOSTKARMA_WL,RP_MATCHES_RCVD,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.1 Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Wed, 08 May 2013 16:21:45 +0000 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r48GLgag007702 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Wed, 8 May 2013 12:21:42 -0400 Received: from [127.0.0.1] (ovpn01.gateway.prod.ext.ams2.redhat.com [10.39.146.11]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id r48GLftT012922; Wed, 8 May 2013 12:21:41 -0400 Message-ID: <518A7B94.6010801@redhat.com> Date: Wed, 08 May 2013 16:21:00 -0000 From: Pedro Alves User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130311 Thunderbird/17.0.4 MIME-Version: 1.0 To: mbilal CC: gdb-patches@sourceware.org, jan.kratochvil@redhat.com Subject: Re: [PATCH 2/7] PR gdb/15224 fix for Unify interactivity tests to use input_from_terminal_p References: <51877A32.1030503@codesourcery.com> <51877A99.4060503@codesourcery.com> <5188AA15.5010904@codesourcery.com> <5188AC27.1050407@codesourcery.com> <5188AC99.6060504@codesourcery.com> <518A0B4E.50808@codesourcery.com> In-Reply-To: <518A0B4E.50808@codesourcery.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-SW-Source: 2013-05/txt/msg00284.txt.bz2 Hi, Thanks for the patch. > ping? Please give it at least a week before pinging. On 05/08/2013 09:22 AM, mbilal wrote: > On 05/07/2013 12:26 PM, mbilal wrote: >> Here is a updated patch for fix for Unify interactivity tests to use input_from_terminal_p: >> Index: event-top.c >> =================================================================== >> RCS file: /cvs/src/src/gdb/event-top.c,v >> retrieving revision 1.94 >> diff -u -p -r1.94 event-top.c >> --- event-top.c 21 Mar 2013 17:37:29 -0000 1.94 >> +++ event-top.c 7 May 2013 07:03:33 -0000 >> @@ -604,7 +604,8 @@ command_line_handler (char *rl) >> >> /* Add line to history if appropriate. */ >> if (instream == stdin >> - && ISATTY (stdin) && *linebuffer) >> + && ISATTY (stdin) && *linebuffer >> + && input_from_terminal_p()) >> add_history (linebuffer); I'd guess that input_from_terminal_p already does some of the checks this is also making, so that this could be simplified. Missing space before parens. A ChangeLog entry is missing. -- Pedro Alves