upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/tests/unit/stubs/esp_system.h
blob: cd5474323757ffdc1ce6b32479ba2c31fb256b52 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#ifndef STUBS_ESP_SYSTEM_H
#define STUBS_ESP_SYSTEM_H

#include <stdlib.h>
#include <stdint.h>

static inline void esp_fill_random(uint8_t *buf, size_t len)
{
    for (size_t i = 0; i < len; i++) {
        buf[i] = (uint8_t)(rand() & 0xFF);
    }
}

#endif