Visual Studio, debug one of multiple threads

前端 未结 7 853
孤街浪徒
孤街浪徒 2020-12-04 14:04

I have an application with 4 threads working the same code. However, when I step it jumps between the different threads. How can I lock it to one thread so the other threads

7条回答
  •  不知归路
    2020-12-04 14:25

    Yes.

    In the Threads window (Debug -> Windows -> Threads) right-click the thread you want and select "switch to thread".

    You can also choose "freeze" on the threads you don't want to debug in order to keep them from running. Don't forget to "thaw" them if you expect them to do work, however.

    Further reading.

提交回复
热议问题