This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 3/7] PR gdb/15224 should "set history save on" by default
- From: Pedro Alves <palves at redhat dot com>
- To: mbilal <mbilal at codesourcery dot com>
- Cc: gdb-patches at sourceware dot org, jan dot kratochvil at redhat dot com
- Date: Wed, 08 May 2013 17:24:22 +0100
- Subject: Re: [PATCH 3/7] PR gdb/15224 should "set history save on" by default
- References: <51877A32 dot 1030503 at codesourcery dot com> <51877A99 dot 4060503 at codesourcery dot com> <51877B42 dot 7 at codesourcery dot com>
On 05/06/2013 10:43 AM, mbilal wrote:
> On Wednesday, April 03, 2013 7:30 PM Jan Kratochvil wrote:
>
>> (3) Fix currently incorrectly touched history file even if no commands get
>
> here is patch
Missing ChangeLog entry.
>
> Index: top.c
> ===================================================================
> RCS file: /cvs/src/src/gdb/top.c,v
> retrieving revision 1.235
> diff -u -p -r1.235 top.c
> --- top.c 17 Apr 2013 01:02:02 -0000 1.235
> +++ top.c 6 May 2013 06:16:04 -0000
> @@ -1430,7 +1430,8 @@ quit_force (char *args, int from_tty)
> /* Save the history information if it is appropriate to do so. */
> DO_TRY
> {
> - if (write_history_p && history_filename)
> + if (write_history_p && history_filename
> + && input_from_terminal_p())
Missing space before parens.
> write_history (history_filename);
> }
> DO_PRINT_EX;
>
>
>
> I have tested
It'd be great if we had that in our testsuite.
--
Pedro Alves