How to properly terminate the DoWork thread function in FAsyncTask?