Hotshot
I have a script that runs a shell I wrote. I want to be able to kill it from the same shell opened by another user but I want to send him a message before I kill him (so he'll know what happen), just using kill('KILL', $pid);
writes 'killed' on his screen, this isn't enough for me.
I tried sending him SIGPIPE, and catch it in his shell (and printing what I wanted) and then using 'exit' or 'die' there, this did the work but also wrecked the Unix shell (pressing 'enter' prints the prompt horizontally instead of vertically, the input I enters doesn't seems on screen, etc.)
can someone help?