diff options
Diffstat (limited to 'sys/kern/kern_thr.c')
-rw-r--r-- | sys/kern/kern_thr.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/kern/kern_thr.c b/sys/kern/kern_thr.c index de45d0a..6bf0ded 100644 --- a/sys/kern/kern_thr.c +++ b/sys/kern/kern_thr.c @@ -175,6 +175,8 @@ create_thread(struct thread *td, mcontext_t *ctx, /* Initialize our td */ newtd = thread_alloc(); + if (newtd == NULL) + return (ENOMEM); /* * Try the copyout as soon as we allocate the td so we don't |