Recall that the Pthread
program (Figure 4.9) had the parent thread wait for the summation thread
using the pthread join() statement.We perform the equivalent of this in the
Windows API using the WaitForSingleObject() function, which causes the
creating thread to block until the summation thread has exited.