Translate and end thread before exit

Translate and end thread before exit