Skip to main content

MAX_LINE_BYTES

Constant MAX_LINE_BYTES 

Source
pub const MAX_LINE_BYTES: usize = _; // 67_108_864usize
Expand description

Hard cap on a single NDJSON line’s size. Without this, a single huge or unterminated line from a buggy or malicious app-server peer would grow read_line’s buffer without bound. 64 MiB comfortably covers legitimate large payloads (e.g. fs/readFile results, big diffs) while still being a real, finite bound.