[PATCH] The gcore command hangs without a terminal
Daniel Jacobowitz
drow@false.org
Tue Mar 27 16:21:00 GMT 2007
On Sun, Feb 25, 2007 at 01:26:42PM +0100, Jan Kratochvil wrote:
> Hi,
>
> The function `attach_command' sets up the terminal by calling
> target_terminal_inferior (). This makes gcore(1) to lock up when being run
> without its controlling terminal.
>
> I do not find a reason for this terminal setup as GDB does not share its
> input/output with the application in the mode of external attached program.
Unfortunately I think this is the wrong place to fix it. You're
commenting out a call to target_terminal_inferior, but there are lots
of other calls to this function - including one any time we continue
the program.
target_terminal_inferior is a call eventually to terminal_inferior.
This checks gdb_has_a_terminal (). How are you calling GDB without a
controlling terminal that still lets gdb_has_a_terminal () return
true? That's probably the right place to fix it.
--
Daniel Jacobowitz
CodeSourcery
More information about the Gdb-patches
mailing list