This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [patch] command_line_input, memory leak
- From: Jim Blandy <jimb at codesourcery dot com>
- To: msnyder at sonic dot net
- Cc: gdb-patches at sourceware dot org
- Date: Mon, 06 Aug 2007 15:35:24 -0700
- Subject: Re: [patch] command_line_input, memory leak
- References: <8664.12.7.175.2.1186285330.squirrel@webmail.sonic.net>
msnyder@sonic.net writes:
> malloced memory may be returned by readline/history_expand even if the
> return value is zero.
If I'm reading right, history_expand *always* stores something in the
pointer referred to by its last argument, if it's non-zero. So this
looks good to me.