LostShootingStar has asked for the wisdom of the Perl Monks concerning the following question:
This is running on a SLES 9 kernel, no NFS or anything. EDIT: to those who replied, i screwed up my original post, so i had to re-write it.my @mntDirs = glob("/mnt/*/clips"); foreach $mntDir (@mntDirs){ my @shallowDirs = glob("$mntDir/*"); foreach $shallowDir (@shallowDirs) { my @deepDirs = glob ("$shallowDir/*"); foreach $deepDir (@deepDirs) { opendir (CUR, "$deepDir") or die; #skip . and .. readdir(CUR); readdir(CUR); while($ent = readdir(CUR)){ print "$ent\n"; } close CUR; } } }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: readdir inconsistent!
by bluto (Curate) on Jun 27, 2007 at 19:17 UTC | |
by LostShootingStar (Novice) on Jun 27, 2007 at 19:28 UTC | |
by shmem (Chancellor) on Jun 27, 2007 at 19:35 UTC | |
|
Re: readdir inconsistent!
by Grundle (Scribe) on Jun 27, 2007 at 19:49 UTC | |
|
Re: readdir inconsistent!
by moritz (Cardinal) on Jun 27, 2007 at 18:57 UTC | |
|
Re: readdir inconsistent!
by jettero (Monsignor) on Jun 27, 2007 at 17:48 UTC | |
by LostShootingStar (Novice) on Jun 27, 2007 at 17:55 UTC | |
|
Re: readdir inconsistent!
by ysth (Canon) on Jun 28, 2007 at 05:25 UTC | |
|
Re: readdir inconsistent!
by zentara (Cardinal) on Jun 28, 2007 at 16:38 UTC |