I have a call to an external program that opens a "modal" window, since it's in the same thread as the main loop it blocks redrawing of the underlying window.
The program runs as a separate process and I am communicating with the program via pipes.
From what I've read it's bad practice to have an additional main loop, so what is the correct way to avoid this lockup?
The question is how to make a separate thread in my own program to do the communication with that program without blocking the entire main loop.