enclose COLLECTION_NAME_MAX_LEN and HEADER_SIZE in parentheses
to prevent future potential issues.
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
|
||||
// We defined the collection name max length to be the size of a `tokenDefinition_t` and remove the
|
||||
// `ADDRESS_LENGTH` which corresponds to `sizeof(contractAddress`).
|
||||
#define COLLECTION_NAME_MAX_LEN sizeof(tokenDefinition_t) - ADDRESS_LENGTH
|
||||
#define COLLECTION_NAME_MAX_LEN (sizeof(tokenDefinition_t) - ADDRESS_LENGTH)
|
||||
|
||||
typedef struct nftInfo_t {
|
||||
char collectionName[COLLECTION_NAME_MAX_LEN];
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
#define TYPE_SIZE 1
|
||||
#define VERSION_SIZE 1
|
||||
#define NAME_LENGTH_SIZE 1
|
||||
#define HEADER_SIZE TYPE_SIZE + VERSION_SIZE + NAME_LENGTH_SIZE
|
||||
#define HEADER_SIZE (TYPE_SIZE + VERSION_SIZE + NAME_LENGTH_SIZE)
|
||||
|
||||
#define CHAIN_ID_SIZE 8
|
||||
#define KEY_ID_SIZE 1
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
#define ALGORITHM_ID_SIZE 1
|
||||
#define SIGNATURE_LENGTH_SIZE 1
|
||||
|
||||
#define HEADER_SIZE TYPE_SIZE + VERSION_SIZE + PLUGIN_NAME_LENGTH_SIZE
|
||||
#define HEADER_SIZE (TYPE_SIZE + VERSION_SIZE + PLUGIN_NAME_LENGTH_SIZE)
|
||||
|
||||
#define MIN_DER_SIG_SIZE 67
|
||||
#define MAX_DER_SIG_SIZE 72
|
||||
|
||||
Reference in New Issue
Block a user