gdb
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gdb] How can I connect to gdb/mi?


From: SirVlad
Subject: [Gdb] How can I connect to gdb/mi?
Date: Fri, 03 Jan 2003 22:42:45 +0300

Hello!
I am working at a program that should invoke gdb and manage it, make it run 
some commands and should store the results (which I hope to obtain via gdb/mi) 
in its data structures.
How can I connect to GDB/MI?
I do
...
fork();
//and then, in the daughter process,
dup2();
execlp(gdb);

But dup2 closes stdin, so I get
~"Hangup detected on fd 0\n"
~"error detected on stdin\n" 

Is there any way to avoid this? Sorry for maybe my question is one of a newbie.
Thank you for reading this.
Cheers,
--
roy.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]