in reply to Run Shell script followed by ctrl-c within perl

Ctrl-C sends SIGINT, i.e. is equivalent to
$ kill -INT pid

For a better way of handling external processes see IPC::Run. For example:

my $h = harness \@cmd, \<<IN, \$out; blah IN run $h; $h->signal('INT'); $h->finish;