Code
Hub
Trending
Following
Digest
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
Index your code
hub
/
github.com/aws/aws-cli
/ fallocate
Function
fallocate
awscli/s3transfer/compat.py:86–90 ·
view source on GitHub ↗
(fileobj, size)
Source
from the content-addressed store, hash-verified
84
85
86
def
fallocate(fileobj, size):
87
if
hasattr(os,
'posix_fallocate'
):
88
os.posix_fallocate(fileobj.fileno(), 0, size)
89
else
:
90
fileobj.truncate(size)
91
92
93
# Import at end of file to avoid circular dependencies
Callers
1
allocate
Method · 0.90
Calls
1
fileno
Method · 0.80
Tested by
no test coverage detected