From: Justin Collins Date: 2006-02-01T14:37:36+09:00 Subject: Re: check for and if not there, create direcory and file Ryan Leavengood wrote: >On 1/30/06, ara.t.howard@noaa.gov wrote: > > >>one cannot both check and/or create a dir in an atomic fashion. in fact, one >>cannot even create a dir in an atomic fashion on some filesystems. about the >>best you can do is >> >> > >While this is true, I think it only matters when one is dealing with >multi-process and/or multi-threaded code, which I doubt the original >poster is. But I know that multi-processing is about all you do Ara, >so I guess it is hard to forget lessons like this! ;) > >Ryan > > Not necessarily - the program could check for the existence of the directory, then something else (another program, the user, etc.) could create or remove the directory. Not very likely, but it could happen. Probably not worth worrying about though, huh? -Justin