You do not close the dirhandle! You should!
Why? Perl will close the handle automatically when it goes out of scope. Closing it yourself only makes sense if you are interested in the return value, and are going to do something different depending on the value. Would you expect a close() to fail, and if it fails, what action would you take?
Abigail
In reply to Re: problems returning from recursive subroutine
by Abigail-II
in thread problems returning from recursive subroutine
by melguin
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |