[prev in list] [next in list] [prev in thread] [next in thread]
List: busybox
Subject: [BusyBox] busybox ash + uClibc + ctrl+c
From: "Soewono Effendi" <SEffendi () web ! de>
Date: 2001-12-27 17:13:32
[Download RAW message or body]
Hi!
I've been trying do reproduce the bug with Ctrl-C described in this milist.
Using ash under busybox 0.60.2 dynamic compiled with uClibc-0.9.5, I got this trace \
file after running tail -f /var/log/messages and then pressing Ctrl-C
-----
Tracing started.
Shell args: "ash"
cmdloop(1) called
showjobs(1) called
dowait(0) called
wait returns -1, status=0
token word tail
pipeline: entered
reread token word tail
reread token word tail
reread token word tail
reread token word tail
token word -f
token word /var/log/messages
token newline
reread token newline
reread token newline
reread token newline
evaltree(0x80d65f4: 1) called
evalcommand(0x80d65f4, 0) called
evalcommand arg: tail
evalcommand arg: -f
evalcommand arg: /var/log/messages
searchexec "tail" returns "/bin/tail"
makejob(0x80d65f4, 1) returns %1
forkshell(%0, 0x80d65f4, 0) called
In parent shell: child = 164
waitforjob(%1) called
dowait(1) called
Child shell 164
normal command: "tail" "-f" "/var/log/messages"
wait returns 164, status=2
Changing status of proc 164 from 0xffffffff to 0x2
Job 1: changing state from 0 to 2
Not printing status: status=2, sig=2
exitshell(130) pid=163
---------
> From man vfork:
Signal handlers are inherited, but not shared. Signals to
the parent arrive after the child releases the parent.
I'm just not sure, if this could cause problem or not.
I changed the following code in function oninit of ash.c
instead of if(rootshell && iflag) ...... :
if (rootshell) {
if (!iflag)
exraise(EXINT);
} else {
signal(SIGINT, SIG_DFL);
raise(SIGINT);
}
/* NOTREACHED */
.
Ctrl-C will __not__ restart the ash now!
But then I got another problem :(
Following shell commands sample entered on the prompt can't be interrupted :(
-----------
while [ 1 ]; do
echo test
sleep 1
done
-----------
If I run the commands from a shell script then I have to press Ctrl-C many time and \
fast! then it will be interrupted.
I hope this info might help.
FYI:
I tried it under
Linux **** 2.4.15-pre5 #11 Sun Dec 9 21:53:35 CET 2001 i586 unknown
Best regards,
-----------------
SEffendi(a)web.de
=================
______________________________________________________________________________
Darf es ein bisschen mehr sein? Mehr Speicher, mehr Mail, mehr Erlebnis,
mehr Prämie, mehr WEB.DE. Der WEB.DE Club - http://club.web.de
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic