mirror of
https://github.com/TomHarte/CLK.git
synced 2026-04-21 02:17:08 +00:00
Doubles down on <cX> over <X.h> for C includes, and usage of the namespace for those types and functions.
This commit is contained in:
@@ -10,7 +10,7 @@
|
||||
|
||||
#include <cstdlib>
|
||||
|
||||
void Memory::Fuzz(uint8_t *buffer, size_t size) {
|
||||
void Memory::Fuzz(uint8_t *buffer, std::size_t size) {
|
||||
unsigned int divider = (static_cast<unsigned int>(RAND_MAX) + 1) / 256;
|
||||
unsigned int shift = 1, value = 1;
|
||||
while(value < divider) {
|
||||
@@ -18,7 +18,7 @@ void Memory::Fuzz(uint8_t *buffer, size_t size) {
|
||||
shift++;
|
||||
}
|
||||
|
||||
for(size_t c = 0; c < size; c++) {
|
||||
for(std::size_t c = 0; c < size; c++) {
|
||||
buffer[c] = static_cast<uint8_t>(std::rand() >> shift);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user