mirror of
https://github.com/genodelabs/genode.git
synced 2025-04-08 20:05:54 +00:00
base-hw: Fix bug in 'thread_resume' syscall.
This commit is contained in:
parent
b7c1404fbf
commit
1b73f80350
@ -1202,7 +1202,10 @@ namespace Kernel
|
||||
*/
|
||||
int resume()
|
||||
{
|
||||
assert (_state == AWAIT_RESUMPTION || _state == ACTIVE)
|
||||
if (_state != AWAIT_RESUMPTION && _state != ACTIVE) {
|
||||
PDBG("Unexpected thread state");
|
||||
return -1;
|
||||
}
|
||||
cpu_scheduler()->insert(this);
|
||||
if (_state == ACTIVE) return 1;
|
||||
_state = ACTIVE;
|
||||
|
Loading…
x
Reference in New Issue
Block a user