This seems like a very basic question but I couldn't find an answer to this yet:
I have a simple C++ command-line application which has its main()
thread and from this it forks a service pthread (BSD thread). This service thread performs the I/O on the console. When I just let it run, it works as expected.
The question is: I would like to pause and single-step only the main()
thread while the service thread continues to run free in the background, but so far the Xcode debugger insists on always pausing or resuming all threads at the same time, apparently (regardless whether the pause was due to clicking the pause icon or hitting a breakpoint in either thread).
Have I overlooked something or is it in fact impossible in Xcode to pause and single-step only one of the threads in a Mac application?
(I'm not questioning that in most cases the observed behaviour is the desired and most practical one, I'd just need single-thread debugging right now.)