`make-directory*` won't raise:
http://docs.racket-lang.org/reference/Filesystem.html?q=temp#%28def._%28%28lib._racket%2Ffile..rkt%29._make-directory%2A%29%29



On Thu, Feb 16, 2017 at 2:33 PM, Dan Liebgold
<[email protected]> wrote:
> Hi -
>
> I have a few racket process running on Windows that need to each ensure the 
> same directory structure exists. I have code like this:
>
> (unless (directory-exists? dir)
>   (make-directory dir))
>
> Well, since they're running in parallel occasionally they race and try to 
> make the directory after another has done so, resulting in an exception.
>
> How can I rewrite this so that it either eats the exception or is atomic?
>
> Thanks,
> Dan
>
> --
> You received this message because you are subscribed to the Google Groups 
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to