[commit 7.6.1 only] [patch gdbserver 7.6.1 only] Fix fd leak regression

Jan Kratochvil
2013-08-29T14:27:27Z

On Thu, 29 Aug 2013 16:17:40 +0200, Pedro Alves wrote:
> Thanks, this looks good to me.

Checked in:
https://sourceware.org/ml/gdb-cvs/2013-08/msg00161.html

> > +set test "system fd behavior is known"
> > +set status [remote_exec target "[standard_output_file $testfile]"]
> > +if { [lindex $status 0] == 0 } {
> > + pass $test
> > +} else {
> > + fail $test
> > +}
> > +remote_exec target "ls -l /proc/self/fd/"
>
> Before gdbserver's fix, do we get one extra fd from the dejagnu
> leak, and another extra from gdbserver's leak? What if we made
> $testfile count open fds, and then compare that between running
> under gdb/gdbserver and just under remote_exec ?

BTW not sure if it is clear but this gdb/testsuite/ part was sent
accidentally, there is even written no real test and I have not checked in
anything as I got stuck on the DejaGNU bug.

I have sent a bugreport to <bug-dejagnu@gnu.org> and it got processed today
although the mail has not yet appeared in the archive:
http://lists.gnu.org/archive/html/bug-dejagnu/

I hope DejaGNU gets fixed soon so the testcase can be later written as
UNSUPPORTED (UNTESTED?) with buggy DejaGNU.

Thanks,
Jan