We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e646469 commit 0740aa5Copy full SHA for 0740aa5
kernel/fork.c
@@ -1490,7 +1490,7 @@ static struct task_struct *copy_process(unsigned long clone_flags,
1490
pid = alloc_pid(p->nsproxy->pid_ns_for_children);
1491
if (IS_ERR(pid)) {
1492
retval = PTR_ERR(pid);
1493
- goto bad_fork_cleanup_io;
+ goto bad_fork_cleanup_thread;
1494
}
1495
1496
@@ -1652,6 +1652,8 @@ static struct task_struct *copy_process(unsigned long clone_flags,
1652
bad_fork_free_pid:
1653
if (pid != &init_struct_pid)
1654
free_pid(pid);
1655
+bad_fork_cleanup_thread:
1656
+ exit_thread(p);
1657
bad_fork_cleanup_io:
1658
if (p->io_context)
1659
exit_io_context(p);
0 commit comments