diff options
Diffstat (limited to 'fs/exec.c')
-rw-r--r-- | fs/exec.c | 8 |
1 files changed, 2 insertions, 6 deletions
@@ -1915,7 +1915,6 @@ static int coredump_wait(int exit_code, struct core_state *core_state) | |||
1915 | { | 1915 | { |
1916 | struct task_struct *tsk = current; | 1916 | struct task_struct *tsk = current; |
1917 | struct mm_struct *mm = tsk->mm; | 1917 | struct mm_struct *mm = tsk->mm; |
1918 | struct completion *vfork_done; | ||
1919 | int core_waiters = -EBUSY; | 1918 | int core_waiters = -EBUSY; |
1920 | 1919 | ||
1921 | init_completion(&core_state->startup); | 1920 | init_completion(&core_state->startup); |
@@ -1934,11 +1933,8 @@ static int coredump_wait(int exit_code, struct core_state *core_state) | |||
1934 | * Make sure nobody is waiting for us to release the VM, | 1933 | * Make sure nobody is waiting for us to release the VM, |
1935 | * otherwise we can deadlock when we wait on each other | 1934 | * otherwise we can deadlock when we wait on each other |
1936 | */ | 1935 | */ |
1937 | vfork_done = tsk->vfork_done; | 1936 | if (tsk->vfork_done) |
1938 | if (vfork_done) { | 1937 | complete_vfork_done(tsk); |
1939 | tsk->vfork_done = NULL; | ||
1940 | complete(vfork_done); | ||
1941 | } | ||
1942 | 1938 | ||
1943 | if (core_waiters) | 1939 | if (core_waiters) |
1944 | wait_for_completion(&core_state->startup); | 1940 | wait_for_completion(&core_state->startup); |