coreutils 5.97; mkdir -p; mkdir: cannot create directory `name': File exists

2006-08-22 Thread Rolf Campbell
I believe there is a race-condition in mkdir -p. Specifically, if the directory does not exist *yet* when stat is called on line #98 of coreutils-5.97/lib/mkdir-p.c, but the directory *does* exist by the time line #190 of the same file calls mkdir(), then the program will error with File

Re: coreutils 5.97; mkdir -p; mkdir: cannot create directory `name': File exists

2006-08-22 Thread Eric Blake
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 From: Rolf Campbell I believe there is a race-condition in mkdir -p. Specifically, if the directory does not exist *yet* when stat is called on line #98 of coreutils-5.97/lib/mkdir-p.c, but the directory *does* exist by the time line #190 of the

Re: coreutils 5.97; mkdir -p; mkdir: cannot create directory `name': File exists

2006-08-22 Thread mwoehlke
Rolf Campbell wrote: I believe there is a race-condition in mkdir -p. Specifically, if the directory does not exist *yet* when stat is called on line #98 of coreutils-5.97/lib/mkdir-p.c, but the directory *does* exist by the time line #190 of the same file calls mkdir(), then the program will

Re: coreutils 5.97; mkdir -p; mkdir: cannot create directory `name': File exists

2006-08-22 Thread Rolf Campbell
Eric Blake wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 From: Rolf Campbell I believe there is a race-condition in mkdir -p. Specifically, if the directory does not exist *yet* when stat is called on line #98 of coreutils-5.97/lib/mkdir-p.c, but the directory *does* exist by the time