Thread is finished correctly.

Signed-off-by: Yuriy Rusinov <yrusinov@gmail.com>