Commit 79bba4b6 authored by Caleb C. Sander's avatar Caleb C. Sander
Browse files

Make secret a byte array to avoid warnings

parent f6947447
No related merge requests found
Showing with 5 additions and 5 deletions
+5 -5
const char SECRET[] = "CLOCK";
const uint8_t SECRET[] = "CLOCK";
static inline char access_secret(size_t i) {
static inline uint8_t access_secret(size_t i) {
return SECRET[i];
}
const char SECRET[] = "CACHE";
const uint8_t SECRET[] = "CACHE";
static inline void cache_secret(void) {
volatile const char *secret = SECRET;
volatile const uint8_t *secret = SECRET;
while (*secret != '\0') {
secret++;
}
}
static inline char access_secret(size_t i) {
static inline uint8_t access_secret(size_t i) {
*(volatile uint8_t *) (i << 16 | 0xFFFF);
return SECRET[i];
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment