Merge pull request #565 from LedgerHQ/cev/B2CA-1558_Port-Flex

B2CA-1558: Port Ethereum on Flex
This commit is contained in:
Charles-Edouard de la Vergne
2024-05-16 17:44:25 +02:00
committed by GitHub
876 changed files with 905 additions and 1021 deletions

View File

@@ -13,6 +13,7 @@ void ui_display_public_key(const uint64_t *chain_id);
void ui_sign_712_v0(void);
void ui_confirm_selector(void);
void ui_confirm_parameter(void);
void app_quit(void);
// EIP-191
void ui_191_start(void);

View File

@@ -58,20 +58,3 @@ void reverseString(char *const str, uint32_t length) {
str[j] = c;
}
}
int bytes_to_string(char *out, size_t outl, const void *value, size_t len) {
if (outl <= 2) {
// Need at least '0x' and 1 digit
return -1;
}
if (strlcpy(out, "0x", outl) != 2) {
goto err;
}
if (format_hex(value, len, out + 2, outl - 2) < 0) {
goto err;
}
return 0;
err:
*out = '\0';
return -1;
}

View File

@@ -35,6 +35,4 @@ void read_u64_be(const uint8_t *const in, uint64_t *const out);
uint64_t readUint64BE(const uint8_t *const buffer);
void reverseString(char *const str, uint32_t length);
int bytes_to_string(char *out, size_t outl, const void *value, size_t len);
#endif //_UINT_COMMON_H_