in reply to A way to report open file handles a Perl script has open?
A hack highly depending on the OS, in other words: It works on my Linux x86_64 computer. Your mileage may vary.
> perl -E 'open my $f,"<","/etc/hosts"; system "/bin/ls","-lF",qq[/pro +c/$$/fd]' < /etc/passwd total 0 lr-x------ 1 alex users 64 Apr 4 20:17 0 -> /etc/passwd lrwx------ 1 alex users 64 Apr 4 20:17 1 -> /dev/pts/0 lrwx------ 1 alex users 64 Apr 4 20:17 2 -> /dev/pts/0 lr-x------ 1 alex users 64 Apr 4 20:17 3 -> /etc/hosts lr-x------ 1 alex users 64 Apr 4 20:17 4 -> pipe:[2099383] >
See also:
Alexander
|
|---|