Made gdb return with exit code of child process.