diff options
author | Jeff Dike <jdike@addtoit.com> | 2005-05-05 19:15:32 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-05-05 19:36:36 -0400 |
commit | cd2ee4a30cc0775d8b54e5b958613361a7cacfec (patch) | |
tree | edea72ea7d723a1c35675632850916d77084581b /arch/um/kernel/tt/tracer.c | |
parent | c578455a3eccf4dd7bd111e77129c301d6d67914 (diff) |
[PATCH] uml: Fix SIGWINCH relaying
This makes SIGWINCH work again, and fixes a couple of SIGWINCH-associated
crashes. First, the sigio thread disables SIGWINCH because all hell breaks
loose if it ever gets one and tries to call the signal handling code. Second,
there was a problem with deferencing tty structs after they were freed. The
SIGWINCH support for a tty wasn't being turned off or freed after the tty went
away.
Signed-off-by: Jeff Dike <jdike@addtoit.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/um/kernel/tt/tracer.c')
-rw-r--r-- | arch/um/kernel/tt/tracer.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/um/kernel/tt/tracer.c b/arch/um/kernel/tt/tracer.c index f7b1753a025c..d11e7399d7a1 100644 --- a/arch/um/kernel/tt/tracer.c +++ b/arch/um/kernel/tt/tracer.c | |||
@@ -26,6 +26,7 @@ | |||
26 | #include "kern_util.h" | 26 | #include "kern_util.h" |
27 | #include "chan_user.h" | 27 | #include "chan_user.h" |
28 | #include "ptrace_user.h" | 28 | #include "ptrace_user.h" |
29 | #include "irq_user.h" | ||
29 | #include "mode.h" | 30 | #include "mode.h" |
30 | #include "tt.h" | 31 | #include "tt.h" |
31 | 32 | ||
@@ -33,7 +34,7 @@ static int tracer_winch[2]; | |||
33 | 34 | ||
34 | int is_tracer_winch(int pid, int fd, void *data) | 35 | int is_tracer_winch(int pid, int fd, void *data) |
35 | { | 36 | { |
36 | if(pid != tracing_pid) | 37 | if(pid != os_getpgrp()) |
37 | return(0); | 38 | return(0); |
38 | 39 | ||
39 | register_winch_irq(tracer_winch[0], fd, -1, data); | 40 | register_winch_irq(tracer_winch[0], fd, -1, data); |
@@ -119,6 +120,7 @@ static int signal_tramp(void *arg) | |||
119 | signal(SIGSEGV, (__sighandler_t) sig_handler); | 120 | signal(SIGSEGV, (__sighandler_t) sig_handler); |
120 | set_cmdline("(idle thread)"); | 121 | set_cmdline("(idle thread)"); |
121 | set_init_pid(os_getpid()); | 122 | set_init_pid(os_getpid()); |
123 | init_irq_signals(0); | ||
122 | proc = arg; | 124 | proc = arg; |
123 | return((*proc)(NULL)); | 125 | return((*proc)(NULL)); |
124 | } | 126 | } |