MCPcopy Index your code
hub / github.com/codeaashu/claude-code / crc32

Function crc32

src/utils/ansiToPng.ts:284–290  ·  view source on GitHub ↗
(data: Uint8Array)

Source from the content-addressed store, hash-verified

282}
283
284function crc32(data: Uint8Array): number {
285 let c = 0xffffffff
286 for (let i = 0; i < data.length; i++) {
287 c = CRC_TABLE[(c ^ data[i]!) & 0xff]! ^ (c >>> 8)
288 }
289 return (c ^ 0xffffffff) >>> 0
290}
291
292function chunk(type: string, data: Uint8Array): Buffer {
293 const body = Buffer.alloc(4 + data.length)

Callers 1

chunkFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected