diff options
-rw-r--r-- | src/stacks.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/stacks.c b/src/stacks.c index df323259..4c8e5df6 100644 --- a/src/stacks.c +++ b/src/stacks.c @@ -629,12 +629,11 @@ yield(void) return; } struct thread_info *cur = getCurThread(); + // Switch to the next thread + switch_next(cur); if (cur == &MainThread) // Permit irqs to fire check_irqs(); - - // Switch to the next thread - switch_next(cur); } void VISIBLE16 |