core: bugfix: handle the no peripheral thread case
core: bugfix: handle the no peripheral thread case

lab11/M-ulator,lab11/M-ulator,lab11/M-ulator,lab11/M-ulator,lab11/M-ulator,lab11/M-ulator,lab11/M-ulator