bt_thread fixes