From f88b47ea2730f17384690f6f223cc2fe17b311a2 Mon Sep 17 00:00:00 2001 From: Tom Cosgrove Date: Wed, 17 Aug 2022 08:42:58 +0100 Subject: [PATCH] Remove 'const' qualifier from temporary for mpi_montmul() Signed-off-by: Tom Cosgrove --- library/bignum.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/library/bignum.c b/library/bignum.c index f60ac16c8b..cfaaf5f20f 100644 --- a/library/bignum.c +++ b/library/bignum.c @@ -1572,12 +1572,10 @@ static void mpi_montg_init( mbedtls_mpi_uint *mm, const mbedtls_mpi *N ) * (T->n >= 2 * N->n + 1). * Its initial content is unused and * its final content is indeterminate. - * Note that unlike the usual convention in the library - * for `const mbedtls_mpi*`, the content of T can change. */ static void mpi_montmul( mbedtls_mpi *A, const mbedtls_mpi *B, const mbedtls_mpi *N, mbedtls_mpi_uint mm, - const mbedtls_mpi *T ) + mbedtls_mpi *T ) { mbedtls_mpi_core_montmul( A->p, A->p, B->p, B->n, N->p, N->n, mm, T->p ); } @@ -1588,7 +1586,7 @@ static void mpi_montmul( mbedtls_mpi *A, const mbedtls_mpi *B, * See mpi_montmul() regarding constraints and guarantees on the parameters. */ static void mpi_montred( mbedtls_mpi *A, const mbedtls_mpi *N, - mbedtls_mpi_uint mm, const mbedtls_mpi *T ) + mbedtls_mpi_uint mm, mbedtls_mpi *T ) { mbedtls_mpi_uint z = 1; mbedtls_mpi U;