@@ -314,30 +314,30 @@ static int chcr_compute_partial_hash(struct shash_desc *desc,
314314 if (digest_size == SHA1_DIGEST_SIZE ) {
315315 error = crypto_shash_init (desc ) ?:
316316 crypto_shash_update (desc , iopad , SHA1_BLOCK_SIZE ) ?:
317- crypto_shash_export (desc , ( void * ) & sha1_st );
317+ crypto_shash_export_core (desc , & sha1_st );
318318 memcpy (result_hash , sha1_st .state , SHA1_DIGEST_SIZE );
319319 } else if (digest_size == SHA224_DIGEST_SIZE ) {
320320 error = crypto_shash_init (desc ) ?:
321321 crypto_shash_update (desc , iopad , SHA256_BLOCK_SIZE ) ?:
322- crypto_shash_export (desc , ( void * ) & sha256_st );
322+ crypto_shash_export_core (desc , & sha256_st );
323323 memcpy (result_hash , sha256_st .state , SHA256_DIGEST_SIZE );
324324
325325 } else if (digest_size == SHA256_DIGEST_SIZE ) {
326326 error = crypto_shash_init (desc ) ?:
327327 crypto_shash_update (desc , iopad , SHA256_BLOCK_SIZE ) ?:
328- crypto_shash_export (desc , ( void * ) & sha256_st );
328+ crypto_shash_export_core (desc , & sha256_st );
329329 memcpy (result_hash , sha256_st .state , SHA256_DIGEST_SIZE );
330330
331331 } else if (digest_size == SHA384_DIGEST_SIZE ) {
332332 error = crypto_shash_init (desc ) ?:
333333 crypto_shash_update (desc , iopad , SHA512_BLOCK_SIZE ) ?:
334- crypto_shash_export (desc , ( void * ) & sha512_st );
334+ crypto_shash_export_core (desc , & sha512_st );
335335 memcpy (result_hash , sha512_st .state , SHA512_DIGEST_SIZE );
336336
337337 } else if (digest_size == SHA512_DIGEST_SIZE ) {
338338 error = crypto_shash_init (desc ) ?:
339339 crypto_shash_update (desc , iopad , SHA512_BLOCK_SIZE ) ?:
340- crypto_shash_export (desc , ( void * ) & sha512_st );
340+ crypto_shash_export_core (desc , & sha512_st );
341341 memcpy (result_hash , sha512_st .state , SHA512_DIGEST_SIZE );
342342 } else {
343343 error = - EINVAL ;
0 commit comments