Fix a few unchecked value issue
Signed-off-by: Chien Wong <m@xv97.com>
diff --git a/library/bignum.c b/library/bignum.c
index d559c9e..7661dd3 100644
--- a/library/bignum.c
+++ b/library/bignum.c
@@ -1706,7 +1706,7 @@
*/
const size_t x_index = 0;
mbedtls_mpi_init(&W[x_index]);
- mbedtls_mpi_copy(&W[x_index], X);
+ MBEDTLS_MPI_CHK(mbedtls_mpi_copy(&W[x_index], X));
j = N->n + 1;
/* All W[i] and X must have at least N->n limbs for the mpi_montmul()
@@ -1893,7 +1893,7 @@
/*
* Load the result in the output variable.
*/
- mbedtls_mpi_copy(X, &W[x_index]);
+ MBEDTLS_MPI_CHK(mbedtls_mpi_copy(X, &W[x_index]));
cleanup: