Re: gdbserver 6.7.1 for mingw32ce connect to host gdb problem

Pedro Alves
2007-12-16T23:48:37Z

> Good suggestions. comments follow below.
>
> summary: pilot error on my part. it turns out that gdbserver.exe MUST be
> launched like this
> gdbserver :9999 /path/test
>
> and must NOT be launched as I attempted previously:
> gdbserver.exe 169.254.2.2:9999 \\path\\test.exe
>

Well, it depends on what kind of "shell" you use to
invoke the command. I was assuming you were
invoking from some remote RAPI tool from some shell
that needed the escaping, but since you seem to be
using MSFT's cmd.exe, you have to use
single back-slashes:
gdbserver.exe 169.254.2.2:9999 \path\test.exe

If that's the case, this is not a gdbserver problem.
If it's something else, it could be a bug.

> interesting test
> b main
> c
> p argc
> $1 = 1
> p argv[0]
> $2 = 0x260930 "\\path\test.exe"
>
> so gdb although invoked with single forward slash,converts to double back
> slash.
>

Actually, it's converted into a single back slash, since that's
what the CreateProcess call used to launch the process expects.
The double back slash is shown because '\' is the escape char. I
guess you have a typo in your example.

Glad it's working now.

--
Pedro Alves