Rather than iterating you could use stat to look at the nlink field; on a *NIX system an empty directory should have exactly two links (one from its parent to itself, and one from its own . entry).
--
We're looking for people in ATL
In reply to Re: checking to see if a directory is empty
by Fletch
in thread checking to see if a directory is empty
by drum1981
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |