> In the timex program in /lymon/homes/cs494/labs/Sh/programs , nothing >seems to be happening (when running of kenner) as follows > >Wael on kenner> pwd >/lymon/homes/cs494/labs/Sh/programs >Wael on kenner> sh >$./timex sleep 100 This waits 60 seconds and then kills the sleep process. When it's done, the sleep and timex are gone. If you do a and bg, you should see that there are two sleeps running -- one for 100 seconds and one for 60. >$ ps > PID TTY TIME CMD > 19745 pts/6 0:00 sh > 18675 pts/6 0:02 tcsh >$ sleep 100 & >19764 >$ ps > PID TTY TIME CMD > 19745 pts/6 0:00 sh > 18675 pts/6 0:02 tcsh > 19764 pts/6 0:00 sleep > >So what exactly is happening in the first example. > >On a related note, why use kill to test for existance and then kill it? >why don't we just kill the process anyway (and capture the result in >/dev/null) even if it doesn't exist? Sure -- that's fine, I'm just making you do more work for the fun of it.