coredump

How do I analyze a program's core dump file with GDB when it has command-line parameters?

别说谁变了你拦得住时间么 提交于 2019-11-25 20:27:00
My program operates like this: exe -p param1 -i param2 -o param3 It crashed and generated a core dump file, core.pid . I want to analyze the core dump file by gdb ./exe -p param1 -i param2 -o param3 core.pid But GDB recognizes the parameters of the EXE file as GDB's input. How do I analyze a core dump file in this situation? another.anon.coward You can use the core with gdb in many ways, but passing parameters which is to be passed to executable to gdb is not the way to use core file. This could also be the reason you got that error. You can use the core file in following ways: gdb <executable