skyworld_chen has asked for the wisdom of the Perl Monks concerning the following question:
I wrote a piece of code named as "cy_find" like this:
use File::Find; .... .... find (\&wanted, "$target_path"); sub wanted { open temp_file_cy, "$File::Find::name; print "hello 1\n" if (-r tep_file_cy); close temp_file_cy; }
it is strange for some files the linux returns :
"-r on closed filehandle temp_file_cy at ../cy_find line 87"
can anybody tell me why I was operating on "closedfilehandle"? thanks
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: quston n File::Find
by 2teez (Vicar) on Oct 30, 2012 at 09:54 UTC | |
by skyworld_chen (Acolyte) on Oct 30, 2012 at 12:09 UTC | |
by aitap (Curate) on Oct 30, 2012 at 17:02 UTC | |
by skyworld_chen (Acolyte) on Oct 31, 2012 at 01:22 UTC | |
|
Re: question on File::Find (cd)
by tye (Sage) on Oct 30, 2012 at 13:40 UTC | |
by skyworld_chen (Acolyte) on Oct 31, 2012 at 01:43 UTC | |
by aitap (Curate) on Oct 31, 2012 at 15:50 UTC | |
by skyworld_chen (Acolyte) on Nov 01, 2012 at 12:55 UTC | |
|
Re: question n File::Find
by zentara (Cardinal) on Oct 30, 2012 at 11:02 UTC | |
by skyworld_chen (Acolyte) on Oct 30, 2012 at 13:28 UTC |