Integrity
Source: src/integrity.c · 18 lines · 1 functions.
Module entry points
These functions are exposed to the rest of the project. Open one to follow its decisions and the helpers it calls.
How to read these diagrams
Each function has its own expandable diagram using the actual expressions and statements from this file. Decisions split into True and False; loop bodies are indented. Returns end the function immediately; break and continue follow their C meanings. Arrows between statements show their order when execution reaches them.
These are structural source diagrams before preprocessing, not runtime traces. Conditional compilation and macros remain source expressions. Ternary choices remain inside their statement. Calls are linked separately; callback execution and task scheduling are not inferred.
Functions in this file
integrity_crc32() · source line 3
uint32_t integrity_crc32(const void *data, size_t size)
- Decision
data == NULLTrue- Exit this function
return 0U;
FalseContinue after this decision.
- Execute
const uint8_t *bytes = data; - Execute
uint32_t crc = 0xFFFFFFFFU; - FOR loop
size_t index = 0; index < size; ++indexRepeat body while the loop condition permits; then continue below.
- Execute
crc ^= bytes[index]; - FOR loop
unsigned bit = 0; bit < 8U; ++bitRepeat body while the loop condition permits; then continue below.
- Execute
crc = (crc >> 1U) ^ ((crc & 1U) != 0U ? 0xEDB88320U : 0U);
- Exit this function
return crc ^ 0xFFFFFFFFU;
Read original function source
uint32_t integrity_crc32(const void *data, size_t size)
{
if (data == NULL) {
return 0U;
}
const uint8_t *bytes = data;
uint32_t crc = 0xFFFFFFFFU;
for (size_t index = 0; index < size; ++index) {
crc ^= bytes[index];
for (unsigned bit = 0; bit < 8U; ++bit) {
crc = (crc >> 1U) ^ ((crc & 1U) != 0U ? 0xEDB88320U : 0U);
}
}
return crc ^ 0xFFFFFFFFU;
}Complete original file, including constants and data
/* Coded By JD(2026) */
#error "Reference listing only — not provided as build-ready source."
#include "integrity.h"
uint32_t integrity_crc32(const void *data, size_t size)
{
if (data == NULL) {
return 0U;
}
const uint8_t *bytes = data;
uint32_t crc = 0xFFFFFFFFU;
for (size_t index = 0; index < size; ++index) {
crc ^= bytes[index];
for (unsigned bit = 0; bit < 8U; ++bit) {
crc = (crc >> 1U) ^ ((crc & 1U) != 0U ? 0xEDB88320U : 0U);
}
}
return crc ^ 0xFFFFFFFFU;
}