This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] An implementation of pipe to make I/O communication between gdb and shell.


On Thu, Aug 4, 2011 at 2:12 PM, Jan Kratochvil
<jan.kratochvil@redhat.com> wrote:
> On Thu, 04 Aug 2011 09:51:14 +0200, Abhijit Halder wrote:
>> If in future some command started using gdb_stdin,
>
> then s/he can Google it out from your mailing list post. ?The GDB codebase
> should be as simple as possible for easier contributions.
>
> I really do not see any (normal) use for gdb_stdin in the GDB codebase now.
>
>
>> Please suggest me whether I should remove these (-r as well as -w) options.
>
> Yes.
>
>
>> I am still not fully familiar with GNU style.
>
> For us non-Emacsists
> ? ? ? ?http://www.gnu.org/prep/standards/standards.html
> suggests
> ? ? ? ?indent -nbad -bap -nbc -bbo -bl -bli2 -bls -ncdb -nce -cp1 -cs -di2 -ndj -nfc1 -nfca -hnl -i2 -ip5 -lp -pcs -psl -nsc -nsob
>
>
> I am sorry you did not comment on the idea of '>' / '>>' etc. redirections,
> I found find it also useful myself.
>
Sorry for this delay. I am not sure about the use-case of redirection.
If someone wants to redirect some specific command output to a file,
s/he can anyway do it using pipe and some useful shell command (e.g.
cat).
These two will be equivalent:
1. (gdb) print variable >somefile
2. (gdb) pipe | print variable | cat somefile
But it will not dump any error message to the file. User may not be
interested in the errors coming from gdb. That is the reason I
purposefully skipped the gdb_stderr to be redirected to pipe. But that
is again doable task.

>
> Thanks,
> Jan
>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]