redbrick has asked for the wisdom of the Perl Monks concerning the following question:

I was debugging (or being humble, trying to seek understanding through following the works left by more experienced people) and when the perl debugger reach the statement

($pid = fork) or last;

the console showed the message:
######### Forked, but do not know how to change a TTY. ######### Define $DB::fork_TTY - or a function DB::get_fork_TTY() which will set $DB::fork_TTY +. The value of $DB::fork_TTY should be the name of TTY to use. On UNIX-like systems one can get the name of a TTY for the given window by typing tty, and disconnect the shell from TTY by sleep 1000000. DB<4> DB<4>

And I found myself lost, because I don't know how to "follow" the child process, nor why the terminal seems so weird, "swallowing" every other char that I type in it.

I don't know if matters, but I am using the PuTTY terminal, through a SSH connection.

So, could anyone help me:
- how do I this mess (the terminal input/output) in right order,
- and continue the debugging, following the child process?

Thanks for all concerns.

Replies are listed 'Best First'.
Re: How do I debug/follow child processes?
by perrin (Chancellor) on May 14, 2002 at 22:46 UTC