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

Function bounded_length

src/daemon/service.c:42–55  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

40}
41
42static bool bounded_length(const char *value, size_t cap, size_t *length_out) {
43 if (!value || cap == 0) {
44 return false;
45 }
46 for (size_t i = 0; i < cap; i++) {
47 if (value[i] == '\0') {
48 if (length_out) {
49 *length_out = i;
50 }
51 return true;
52 }
53 }
54 return false;
55}
56
57static bool version_valid(const char *version) {
58 size_t length = 0;

Callers 6

version_validFunction · 0.85
fingerprint_validFunction · 0.85
json_escape_versionFunction · 0.85
posix_log_path_openFunction · 0.85
windows_log_path_openFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected