Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
848 views
in Technique[技术] by (71.8m points)

debugging - C++ figure out if the debugger is attached

I use stackwalk64 to generate stacktraces for C++ in visual studio 2008 using the latest symchk.exe and dbghlp.dll. This works fine when I'm running the standalone exe. However, when the debugger is attached I deadlock visual studio. I previously had a workaround where I downloaded all of the system32 symbols to disk and this worked well, but a recent update seems to have broken my workaround even though I updated the symbols. Ideally I would like to determine if the visual studio debugger is attached (it will only ever be the VS debugger) so I can turn off my stack traces in that case. Thanks for any help.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...