June 2017
Intermediate to advanced
478 pages
13h 14m
English
Gdbserver loads the program into memory and sets a breakpoint at the first instruction, then waits for a connection from GDB. When the connection is made, you enter into a debug session. However, you will find that if you try to single-step immediately, you will get this message:
Cannot find bounds of current function
This is because the program has been halted in code written in assembly which creates the runtime environment for C and C++ programs. The first line of C or C++ code is the main() function. Supposing that you want to stop at main(), you would set a breakpoint there and then use the continue command (abbreviation c) to tell gdbserver to continue from the breakpoint at the start of the program and stop ...
Read now
Unlock full access