Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

rename is not atomic on win32. That’s a posix-ism.


Windows 10 1607 and newer support it now if you call SetFileInformationByHandle() with FileRenameInfoEx and specify the FILE_RENAME_FLAG_POSIX_SEMANTICS flag. Not sure how commonly it's used in standard libraries, but I've seen it popping up more and more.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: