Hi,

What am I doing wrong? And yes I know that there is a module for chmod but it is not loaded on this server that I need to run this on.

use strict;
use File::Find ();

*name = *File::Find::name;

File::Find::find({\&FixMode},  '.');
exit;

sub FixMode {
   my ($dev,$ino,$mode,$nlink,$uid,$gid);
   my ($nmode,$omode);

(($dev,$ino,$mode,$nlink,$uid,$gid) = lstat($_)) && -f _ &&
((($mode & 02) == 02) || (($mode & 020) == 020)) &&
chmod sprintf("0%o", ($mode & 0755)), $name;
}
--
Your favorite stores, helpful shopping tools and great gift ideas. Experience the convenience of buying online with [EMAIL PROTECTED] http://shopnow.netscape.com/



-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>




Reply via email to