MCPcopy Create free account
hub / github.com/DeusData/codebase-memory-mcp / cv2_copy

Function cv2_copy

src/mcp/test_impact_coverage.c:684–698  ·  view source on GitHub ↗

Chunk all explicit bulk work; allocator internals are not a polling API. */

Source from the content-addressed store, hash-verified

682
683/* Chunk all explicit bulk work; allocator internals are not a polling API. */
684static bool cv2_copy(cv2_context_t *ctx, void *to, const void *from, size_t length) {
685 unsigned char *dst = to;
686 const unsigned char *src = from;
687 size_t at = 0;
688 while (at < length) {
689 if (!cv2_poll(ctx))
690 return false;
691 size_t chunk = length - at;
692 if (chunk > 4096)
693 chunk = 4096;
694 memcpy(dst + at, src + at, chunk);
695 at += chunk;
696 }
697 return cv2_poll(ctx);
698}
699
700static bool cv2_zero(cv2_context_t *ctx, void *memory, size_t length) {
701 unsigned char *bytes = memory;

Callers 1

cv2_stringFunction · 0.85

Calls 1

cv2_pollFunction · 0.85

Tested by

no test coverage detected