Skip to content

Commit 821c492

Browse files
committed
Merge branch 'neilt6-master'
2 parents 275100e + 327bd41 commit 821c492

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

rtos/rtx/TARGET_CORTEX_A/rt_CMSIS.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -905,7 +905,7 @@ uint8_t osThreadGetState (osThreadId thread_id) {
905905
if (__exceptional_mode()) return osErrorISR; // Not allowed in ISR
906906

907907
ptcb = rt_tid2ptcb(thread_id); // Get TCB pointer
908-
if (ptcb == NULL) return osErrorParameter;
908+
if (ptcb == NULL) return INACTIVE;
909909

910910
return ptcb->state;
911911
}

rtos/rtx/TARGET_CORTEX_M/rt_CMSIS.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -842,7 +842,7 @@ uint8_t osThreadGetState (osThreadId thread_id) {
842842
if (__get_IPSR() != 0U) return osErrorISR; // Not allowed in ISR
843843

844844
ptcb = rt_tid2ptcb(thread_id); // Get TCB pointer
845-
if (ptcb == NULL) return osErrorParameter;
845+
if (ptcb == NULL) return INACTIVE;
846846

847847
return ptcb->state;
848848
}

0 commit comments

Comments
 (0)