Lauri Tirkkonen wrote: > Hi, it seems install(1) has a race condition: in create_newfile, it > first unlinks the target file and then tries to open it with > O_CREAT|O_EXCL.
> The below diff essentially removes the -S option and makes install > always use temp files (ie. -S is always on), eliminating the race since > rename(2) cannot fail like this. I don't know. Presumably if there weren't any downside to safecopy, it would already have been made the default. This doubles the number of synchronous file operations. You should probably fix your project to use -S instead.
