fix crash when target is not running