Working on net thread
- Added safe thread destruction