Commit d691958b authored by Rusty Russell's avatar Rusty Russell Committed by David S. Miller

[PATCH] Enable signals for usermode helpers

Stelian Pop reported that all signals are blocked in processes
execed from the kernel as usermode helpers.
parent fd0dacff
...@@ -152,6 +152,14 @@ static int ____call_usermodehelper(void *data) ...@@ -152,6 +152,14 @@ static int ____call_usermodehelper(void *data)
struct subprocess_info *sub_info = data; struct subprocess_info *sub_info = data;
int retval; int retval;
/* Unblock all signals. */
flush_signals(current);
spin_lock_irq(&current->sighand->siglock);
flush_signal_handlers(current);
sigemptyset(&current->blocked);
recalc_sigpending();
spin_unlock_irq(&current->sighand->siglock);
retval = -EPERM; retval = -EPERM;
if (current->fs->root) if (current->fs->root)
retval = execve(sub_info->path, sub_info->argv,sub_info->envp); retval = execve(sub_info->path, sub_info->argv,sub_info->envp);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment