aboutsummaryrefslogtreecommitdiff
path: root/arch/um/kernel/exec.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/um/kernel/exec.c')
-rw-r--r--arch/um/kernel/exec.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/arch/um/kernel/exec.c b/arch/um/kernel/exec.c
index 0561c43b468..8d56ec6cca7 100644
--- a/arch/um/kernel/exec.c
+++ b/arch/um/kernel/exec.c
@@ -39,12 +39,13 @@ static long execve1(char *file, char __user * __user *argv,
char __user *__user *env)
{
long error;
+ struct tty_struct *tty;
#ifdef CONFIG_TTY_LOG
mutex_lock(&tty_mutex);
- task_lock(current); /* FIXME: is this needed ? */
- log_exec(argv, current->signal->tty);
- task_unlock(current);
+ tty = get_current_tty();
+ if (tty)
+ log_exec(argv, tty);
mutex_unlock(&tty_mutex);
#endif
error = do_execve(file, argv, env, &current->thread.regs);