summaryrefslogtreecommitdiff
path: root/utils/imxtools/sbtools/misc.c
diff options
context:
space:
mode:
Diffstat (limited to 'utils/imxtools/sbtools/misc.c')
-rw-r--r--utils/imxtools/sbtools/misc.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/utils/imxtools/sbtools/misc.c b/utils/imxtools/sbtools/misc.c
index 6216ae612b..c5832b6bb9 100644
--- a/utils/imxtools/sbtools/misc.c
+++ b/utils/imxtools/sbtools/misc.c
@@ -58,7 +58,7 @@ void *xmalloc(size_t s)
58 return r; 58 return r;
59} 59}
60 60
61int convxdigit(char digit, byte *val) 61int convxdigit(char digit, uint8_t *val)
62{ 62{
63 if(digit >= '0' && digit <= '9') 63 if(digit >= '0' && digit <= '9')
64 { 64 {
@@ -127,7 +127,7 @@ bool parse_key(char **pstr, struct crypto_key_t *key)
127 { 127 {
128 for(int j = 0; j < 128; j++) 128 for(int j = 0; j < 128; j++)
129 { 129 {
130 byte a, b; 130 uint8_t a, b;
131 if(convxdigit(str[2 * j], &a) || convxdigit(str[2 * j + 1], &b)) 131 if(convxdigit(str[2 * j], &a) || convxdigit(str[2 * j + 1], &b))
132 return false; 132 return false;
133 key->u.xor_key[j / 64].key[j % 64] = (a << 4) | b; 133 key->u.xor_key[j / 64].key[j % 64] = (a << 4) | b;
@@ -143,7 +143,7 @@ bool parse_key(char **pstr, struct crypto_key_t *key)
143 return false; 143 return false;
144 for(int j = 0; j < 16; j++) 144 for(int j = 0; j < 16; j++)
145 { 145 {
146 byte a, b; 146 uint8_t a, b;
147 if(convxdigit(str[2 * j], &a) || convxdigit(str[2 * j + 1], &b)) 147 if(convxdigit(str[2 * j], &a) || convxdigit(str[2 * j + 1], &b))
148 return false; 148 return false;
149 key->u.key[j] = (a << 4) | b; 149 key->u.key[j] = (a << 4) | b;
@@ -243,7 +243,7 @@ bool add_keys_from_file(const char *key_file)
243 return true; 243 return true;
244} 244}
245 245
246void print_hex(void *user, misc_printf_t printf, byte *data, int len, bool newline) 246void print_hex(void *user, misc_printf_t printf, uint8_t *data, int len, bool newline)
247{ 247{
248 for(int i = 0; i < len; i++) 248 for(int i = 0; i < len; i++)
249 printf(user, "%02X ", data[i]); 249 printf(user, "%02X ", data[i]);