MCPcopy Index your code
hub / github.com/python/cpython / _sync_flush

Function _sync_flush

Lib/mailbox.py:2199–2203  ·  view source on GitHub ↗

Ensure changes to file f are physically on disk.

(f)

Source from the content-addressed store, hash-verified

2197 os.getpid()))
2198
2199def _sync_flush(f):
2200 """Ensure changes to file f are physically on disk."""
2201 f.flush()
2202 if hasattr(os, 'fsync'):
2203 os.fsync(f.fileno())
2204
2205def _sync_close(f):
2206 """Close file f, ensuring all changes are physically on disk."""

Callers 2

flushMethod · 0.85
_sync_closeFunction · 0.85

Calls 3

flushMethod · 0.45
fsyncMethod · 0.45
filenoMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…