Use INT256_LENGTH and ADDRESS_LENGTH define
This commit is contained in:
@@ -12,7 +12,7 @@ typedef enum { TARGET_ADDRESS = 0, TARGET_CONTRACT, TARGET_COMPOUND } targetType
|
||||
typedef struct erc20_parameters_t {
|
||||
uint8_t selectorIndex;
|
||||
uint8_t destinationAddress[21];
|
||||
uint8_t amount[32];
|
||||
uint8_t amount[INT256_LENGTH];
|
||||
uint8_t ticker_1[MAX_TICKER_LEN];
|
||||
uint8_t ticker_2[MAX_TICKER_LEN];
|
||||
uint8_t decimals;
|
||||
|
||||
@@ -10,8 +10,8 @@ void starkware_print_eth_address(uint8_t *address, char *destination);
|
||||
|
||||
typedef struct erc721_parameters_t {
|
||||
uint8_t selectorIndex;
|
||||
uint8_t address[20];
|
||||
uint8_t tokenId[32];
|
||||
uint8_t address[ADDRESS_LENGTH];
|
||||
uint8_t tokenId[INT256_LENGTH];
|
||||
// tokenDefinition_t *tokenSelf;
|
||||
// tokenDefinition_t *tokenAddress;
|
||||
} erc721_parameters_t;
|
||||
|
||||
@@ -352,7 +352,7 @@ void starkware_print_asset_contract(char *destination) {
|
||||
|
||||
// TODO : rewrite as independant code
|
||||
void starkware_get_source_address(char *destination) {
|
||||
uint8_t privateKeyData[32];
|
||||
uint8_t privateKeyData[INT256_LENGTH];
|
||||
cx_ecfp_private_key_t privateKey;
|
||||
cx_ecfp_public_key_t publicKey;
|
||||
os_perso_derive_node_bip32(CX_CURVE_256K1,
|
||||
|
||||
Reference in New Issue
Block a user