Revert "Assume F_FULLFSYNC on darwin"
This commit is contained in:
parent
8c69bb71aa
commit
7e29d9b5c3
@ -6,7 +6,6 @@
|
|||||||
|
|
||||||
* Fallback if RENAME_EXCHANGE is not supportd by the filesystem
|
* Fallback if RENAME_EXCHANGE is not supportd by the filesystem
|
||||||
* Assume POSIX compatibility if `sys.platform` is not `win32`
|
* Assume POSIX compatibility if `sys.platform` is not `win32`
|
||||||
* Assume `F_FULLFSYNC` always exists if `sys.platform` is `darwin`
|
|
||||||
|
|
||||||
## 3.1.3
|
## 3.1.3
|
||||||
|
|
||||||
|
@ -193,7 +193,7 @@ def rename_exchange(src: str, dst: str) -> None:
|
|||||||
|
|
||||||
|
|
||||||
def fsync(fd: int) -> None:
|
def fsync(fd: int) -> None:
|
||||||
if sys.platform == "darwin":
|
if sys.platform != "win32" and hasattr(fcntl, "F_FULLFSYNC"):
|
||||||
fcntl.fcntl(fd, fcntl.F_FULLFSYNC)
|
fcntl.fcntl(fd, fcntl.F_FULLFSYNC)
|
||||||
else:
|
else:
|
||||||
os.fsync(fd)
|
os.fsync(fd)
|
||||||
|
Loading…
Reference in New Issue
Block a user