MCPcopy Create free account
hub / github.com/cloudflare/computer / blocksForSize

Function blocksForSize

packages/computerd/src/fuse/driver.ts:39–41  ·  view source on GitHub ↗
(size: number)

Source from the content-addressed store, hash-verified

37const PREFERRED_IO_BLOCK_SIZE = 4096;
38
39function blocksForSize(size: number): number {
40 return size <= 0 ? 0 : Math.ceil(size / STAT_BLOCK_SIZE);
41}
42
43type StatusCallback = (errnoOrBytes: number) => void;
44type ResultCallback<T> = (errno: number, result: T) => void;

Callers 3

pendingStatFunction · 0.85
getattrFunction · 0.85
statNodeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected