Fixed usage of 8-bit modulo operator off-by-one maximum. (#901)

This commit is contained in:
Steve Karg
2025-02-04 13:56:53 -06:00
committed by GitHub
parent 19ef7f74cd
commit 77bdaaf853
5 changed files with 7 additions and 7 deletions
+1 -1
View File
@@ -474,7 +474,7 @@ void Device_UUID_Init(void)
/* 1. Generate 16 random bytes = 128 bits */
for (i = 0; i < sizeof(Device_UUID); i++) {
Device_UUID[i] = rand() % 255;
Device_UUID[i] = rand() % 256;
}
/* 2. Adjust certain bits according to RFC 4122 section 4.4.
This just means do the following