Menu

#924 GDBServer constantly crashes: Assertion `find_thread_process (process) == NULL' failed

v1.0 (example)
open
nobody
None
1
2021-12-28
2021-12-28
No

I am trying to remotely debug a Windows application compiled with MinGW-w64 compiler from MSYS2.

dummy@KS-win10eng-dbg:/mnt/c/msys64/mingw64/bin$ ./gdbserver.exe --version
GNU gdbserver (GDB) 11.1
Copyright (C) 2021 Free Software Foundation, Inc.
gdbserver is free software, covered by the GNU General Public License.
This gdbserver was configured as "x86_64-w64-mingw32"

dummy@KS-win10eng-dbg:/mnt/c/msys64/mingw64/bin$ ./g++.exe --version
g++.exe (Rev5, Built by MSYS2 project) 11.2.0
Copyright (C) 2021 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

But the server constantlty crashes at random point of execution with the message:

dummy@KS-win10eng-dbg:/mnt/c/msys64/mingw64/bin$ $debug
Listening on port 1234
Remote debugging from host 10.251.74.23, port 58804
Detaching from process 4356
../../gdb-11.1t/erminate called without an active exception
gdbserver/inferiors.cc:159: A problem internal to GDBserver has been detected.
void remove_process(process_info*): Assertion `find_thread_process (process) == NULL' failed.

I tried building with:
- g++.exe
- x86_64-w64-mingw32-g++
- x86_64-w64-mingw32-g++-posix

What causes this?


The Server will crash even on a simple program with one breakpoint if you wait for some time:

int main()
{
    return 0; // breakpoint here
}

Discussion


Log in to post a comment.