MCPcopy Create free account
hub / github.com/Moddable-OpenSource/moddable / fxWriteChunkBigInt

Function fxWriteChunkBigInt

xs/sources/xsSnapshot.c:2023–2035  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2021}
2022
2023void fxWriteChunkBigInt(txMachine* the, txSnapshot* snapshot, void* address, txSize size)
2024{
2025 txChunk* chunk = (txChunk*)(((txByte*)(address)) - sizeof(txChunk));
2026 if (chunk->size & mxChunkFlag) {
2027 txByte* temporary = chunk->temporary;
2028 size <<= 2;
2029 chunk->size &= ~mxChunkFlag;
2030 chunk->temporary = C_NULL;
2031 mxThrowIf((*snapshot->write)(snapshot->stream, chunk, sizeof(txChunk) + size));
2032 chunk->temporary = temporary;
2033 fxWriteChunkZero(the, snapshot, chunk->size - sizeof(txChunk) - size);
2034 }
2035}
2036
2037void fxWriteChunkData(txMachine* the, txSnapshot* snapshot, void* address)
2038{

Callers 1

fxWriteChunkFunction · 0.85

Calls 1

fxWriteChunkZeroFunction · 0.85

Tested by

no test coverage detected