On Wed, Nov 17, 2004 at 11:07:19PM -0800, Yitzchak Scott-Thoennes wrote:

> So something like:
> 
> my $pid = open(REALPATH, "-|");
> if (! $pid) {
>    exec('/usr/bin/fullpath', '-t', $path) if defined $pid;
>    die "Can't open /usr/bin/fullpath: $!";
> }

Except that after a failed exec you should ideally be doing POSIX::_exit()
if it's available, to avoid double flushing IO buffers.

Nicholas Clark

Reply via email to