I'm going to throw this out there, you should exchange information via signals/slots. When you get a cancel use terminate() slot. That will stop it from freezing you program from the looks of it.