summaryrefslogtreecommitdiff
path: root/utils/imxtools/sbtools/crypto.c
diff options
context:
space:
mode:
Diffstat (limited to 'utils/imxtools/sbtools/crypto.c')
-rw-r--r--utils/imxtools/sbtools/crypto.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/utils/imxtools/sbtools/crypto.c b/utils/imxtools/sbtools/crypto.c
index d4afc6c816..4f7b799dd9 100644
--- a/utils/imxtools/sbtools/crypto.c
+++ b/utils/imxtools/sbtools/crypto.c
@@ -68,7 +68,7 @@ int crypto_apply(
68 { 68 {
69 if(out_cbc_mac && !encrypt) 69 if(out_cbc_mac && !encrypt)
70 memcpy(*out_cbc_mac, in_data + 16 * (nr_blocks - 1), 16); 70 memcpy(*out_cbc_mac, in_data + 16 * (nr_blocks - 1), 16);
71 71
72 libusb_device_handle *handle = NULL; 72 libusb_device_handle *handle = NULL;
73 libusb_context *ctx; 73 libusb_context *ctx;
74 /* init library */ 74 /* init library */
@@ -97,7 +97,7 @@ int crypto_apply(
97 printf("usbotp: configuration: %d\n", config_id); 97 printf("usbotp: configuration: %d\n", config_id);
98 printf("usbotp: interfaces: %d\n", config->bNumInterfaces); 98 printf("usbotp: interfaces: %d\n", config->bNumInterfaces);
99 } 99 }
100 100
101 const struct libusb_endpoint_descriptor *endp = NULL; 101 const struct libusb_endpoint_descriptor *endp = NULL;
102 int intf, intf_alt; 102 int intf, intf_alt;
103 for(intf = 0; intf < config->bNumInterfaces; intf++) 103 for(intf = 0; intf < config->bNumInterfaces; intf++)
@@ -147,7 +147,7 @@ int crypto_apply(
147 buffer_size, &recv_size, 1000); 147 buffer_size, &recv_size, 1000);
148 libusb_release_interface(handle, intf); 148 libusb_release_interface(handle, intf);
149 libusb_close(handle); 149 libusb_close(handle);
150 150
151 if(ret < 0) 151 if(ret < 0)
152 { 152 {
153 if(g_debug) 153 if(g_debug)
@@ -166,7 +166,7 @@ int crypto_apply(
166 memcpy(out_data, buffer + 16, 16 * nr_blocks); 166 memcpy(out_data, buffer + 16, 16 * nr_blocks);
167 if(out_cbc_mac && encrypt) 167 if(out_cbc_mac && encrypt)
168 memcpy(*out_cbc_mac, buffer + buffer_size - 16, 16); 168 memcpy(*out_cbc_mac, buffer + buffer_size - 16, 16);
169 169
170 return CRYPTO_ERROR_SUCCESS; 170 return CRYPTO_ERROR_SUCCESS;
171 } 171 }
172 #endif 172 #endif