Skip to main content

parse_cache

Function parse_cache 

Source
pub fn parse_cache(json: &str) -> Option<CmdCache>
Expand description

Parse a cache from JSON, returning None on any failure.

Rejects inputs that are too large, have too many command entries, use an unexpected version, or have a malformed fingerprint. This is a defense-in-depth measure — the cache is untrusted input from an environment variable.