I'd like my thread to do something after quiting, when stop method is called.
For example I have opened file in my thread, and I want to close it when thread is stopping.
How to do it?