Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 47944
b: refs/heads/master
c: 3e7cd6c
h: refs/heads/master
v: v3
  • Loading branch information
Eric W. Biederman authored and Linus Torvalds committed Feb 12, 2007
1 parent 0454c12 commit f1326b6
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 0475ac0845f9295bc5f69af45f58dff2c104c8d1
refs/heads/master: 3e7cd6c413c9e6fbb5e1ee2acdadb4ababd2d474
2 changes: 1 addition & 1 deletion trunk/drivers/char/n_tty.c
Original file line number Diff line number Diff line change
Expand Up @@ -1188,7 +1188,7 @@ static int job_control(struct tty_struct *tty, struct file *file)
printk("read_chan: tty->pgrp <= 0!\n");
else if (process_group(current) != tty->pgrp) {
if (is_ignored(SIGTTIN) ||
is_orphaned_pgrp(process_group(current)))
is_current_pgrp_orphaned())
return -EIO;
kill_pg(process_group(current), SIGTTIN, 1);
return -ERESTARTSYS;
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/char/tty_io.c
Original file line number Diff line number Diff line change
Expand Up @@ -1118,7 +1118,7 @@ int tty_check_change(struct tty_struct * tty)
return 0;
if (is_ignored(SIGTTOU))
return 0;
if (is_orphaned_pgrp(process_group(current)))
if (is_current_pgrp_orphaned())
return -EIO;
(void) kill_pg(process_group(current), SIGTTOU, 1);
return -ERESTARTSYS;
Expand Down
2 changes: 1 addition & 1 deletion trunk/include/linux/tty.h
Original file line number Diff line number Diff line change
Expand Up @@ -303,7 +303,7 @@ extern int tty_read_raw_data(struct tty_struct *tty, unsigned char *bufp,
int buflen);
extern void tty_write_message(struct tty_struct *tty, char *msg);

extern int is_orphaned_pgrp(int pgrp);
extern int is_current_pgrp_orphaned(void);
extern int is_ignored(int sig);
extern int tty_signal(int sig, struct tty_struct *tty);
extern void tty_hangup(struct tty_struct * tty);
Expand Down
4 changes: 2 additions & 2 deletions trunk/kernel/exit.c
Original file line number Diff line number Diff line change
Expand Up @@ -229,12 +229,12 @@ static int will_become_orphaned_pgrp(struct pid *pgrp, struct task_struct *ignor
return ret; /* (sighing) "Often!" */
}

int is_orphaned_pgrp(int pgrp)
int is_current_pgrp_orphaned(void)
{
int retval;

read_lock(&tasklist_lock);
retval = will_become_orphaned_pgrp(find_pid(pgrp), NULL);
retval = will_become_orphaned_pgrp(task_pgrp(current), NULL);
read_unlock(&tasklist_lock);

return retval;
Expand Down
2 changes: 1 addition & 1 deletion trunk/kernel/signal.c
Original file line number Diff line number Diff line change
Expand Up @@ -1909,7 +1909,7 @@ int get_signal_to_deliver(siginfo_t *info, struct k_sigaction *return_ka,

/* signals can be posted during this window */

if (is_orphaned_pgrp(process_group(current)))
if (is_current_pgrp_orphaned())
goto relock;

spin_lock_irq(&current->sighand->siglock);
Expand Down

0 comments on commit f1326b6

Please sign in to comment.