diff --git a/c/qrcodegen.c b/c/qrcodegen.c index 7a1c052..01c04d3 100644 --- a/c/qrcodegen.c +++ b/c/qrcodegen.c @@ -23,7 +23,6 @@ */ #include -#include #include #include "qrcodegen.h" @@ -45,6 +44,7 @@ static uint8_t finiteFieldMultiply(uint8_t x, uint8_t y); /*---- Function implementations ----*/ +// Public function - see documentation comment in header file. bool qrcodegen_isAlphanumeric(const char *text) { for (; *text != '\0'; text++) { char c = *text; @@ -70,6 +70,7 @@ bool qrcodegen_isAlphanumeric(const char *text) { } +// Public function - see documentation comment in header file. bool qrcodegen_isNumeric(const char *text) { for (; *text != '\0'; text++) { char c = *text; @@ -147,7 +148,7 @@ static void initializeFunctionalModules(int version, uint8_t qrcode[]) { } // Fill numerous alignment patterns - uint8_t alignPatPos[7] = {}; + uint8_t alignPatPos[7] = {0}; int numAlign = getAlignmentPatternPositions(version, alignPatPos); for (int i = 0; i < numAlign; i++) { for (int j = 0; j < numAlign; j++) { diff --git a/c/qrcodegen.h b/c/qrcodegen.h index 1d6448c..cbc8458 100644 --- a/c/qrcodegen.h +++ b/c/qrcodegen.h @@ -25,6 +25,7 @@ #pragma once #include +#include /*