6e9faaa874
Large PDFs (50 MB+) crashed on import/open. pdf.js requests hundreds of byte ranges in a burst while parsing the document structure, and foliate-js makePDF dispatched them all concurrently. On Android each read is served through the WebView's rangefile custom scheme (shouldInterceptRequest); the flood of simultaneous native requests exhausts the WebView's Java heap (OutOfMemoryError in handleRequest). Bump foliate-js to cap in-flight range reads at 6 (the implicit per-host limit a real HTTP transport already gets), and add a regression test asserting makePDF keeps at most 6 range reads in flight. Verified live on a Xiaomi 13 (Android 16 / WebView 147) via CDP: max concurrent range reads drop from 753 to 6 with no change in open time. Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>