This generates a classic race condition. To avoid that you need to have this function open the file with the O_EXCL flag specified and then retry with the next free file name if that fails.
- tye (but my friends call me "Tye")In reply to (tye)Re: Unique filename
by tye
in thread Unique filename
by tachyon
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |