in reply to Re: mkdir with variable mask
in thread mkdir with variable mask

Why do you want to give it the same permissions as its parent?
Honestly, now that you mention it, I don't really know. Probably I just saw that you could set the permissions with mkdir and thought that I had to. Which is, of course, nonsene. I had a very strange day yesterday anyway, so I just blame my general dizziness for this. ;-)

Thank you all for your helpful insights. I am not experienced enough at the moment to know what exactly race conditions are, but it seems like a good idea to avoid them, so I will keep that in mind.

One more question though, regarding linuxer's answer:

I looked at File::Spec and I wondered whether there is a reason why you are using catfile instead of catdir.

Alex

Replies are listed 'Best First'.
Re^3: mkdir with variable mask
by linuxer (Curate) on Jan 27, 2009 at 12:24 UTC

    Good point. until now, I used catfile more often than catdir, so it came faster to my mind.

    I will correct my codes accordingly. catdir should be used here.