Force size fields in storage to be 32 bit

Better storage compatibility between 64 bit and 32 bit builds.
pull/25/head
Jochen Hoenicke 7 years ago committed by Pavol Rusnak
parent 0127c1a374
commit 068f013bc6

@ -35,7 +35,7 @@
#define STORAGE_BYTES(NAME, SIZE) \ #define STORAGE_BYTES(NAME, SIZE) \
bool has_##NAME; \ bool has_##NAME; \
struct { \ struct { \
size_t size; \ uint32_t size; \
uint8_t bytes[SIZE]; \ uint8_t bytes[SIZE]; \
} NAME; } NAME;
@ -48,7 +48,7 @@ typedef struct {
uint32_t fingerprint; uint32_t fingerprint;
uint32_t child_num; uint32_t child_num;
struct { struct {
size_t size; uint32_t size;
uint8_t bytes[32]; uint8_t bytes[32];
} chain_code; } chain_code;

Loading…
Cancel
Save