From 5005edb36cd2a51d86cfec72c8568121897aa5d1 Mon Sep 17 00:00:00 2001 From: Janos Follath Date: Tue, 19 Jul 2022 12:45:13 +0100 Subject: [PATCH] Fix typos Signed-off-by: Janos Follath --- library/bignum_mod.h | 6 +++--- library/bignum_mod_raw.h | 6 +++--- library/bignum_new.c | 8 ++++---- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/library/bignum_mod.h b/library/bignum_mod.h index 62ecf2b0d..7eac1df1c 100644 --- a/library/bignum_mod.h +++ b/library/bignum_mod.h @@ -56,8 +56,8 @@ typedef enum MBEDTLS_MPI_MOD_REP_OPT_RED } mbedtls_mpi_mod_rep_selector; -#define MBEDTLS_MI_MOD_EXT_REP_LE 0x1 -#define MBEDTLS_MI_MOD_EXT_REP_BE 0x2 +#define MBEDTLS_MPI_MOD_EXT_REP_LE 0x1 +#define MBEDTLS_MPI_MOD_EXT_REP_BE 0x2 void mbedtls_mpi_mod_residue_release( mbedtls_mpi_mod_residue *r ); @@ -67,7 +67,7 @@ int mbedtls_mpi_mod_residue_setup( mbedtls_mpi_mod_residue *r, void mbedtls_mpi_mod_modulus_init( mbedtls_mpi_mod_modulus *m ); -void mbedtls_mpi_mod_modulus_init( mbedtls_mpi_mod_modulus *m ); +void mbedtls_mpi_mod_modulus_free( mbedtls_mpi_mod_modulus *m ); int mbedtls_mpi_mod_modulus_setup( mbedtls_mpi_mod_modulus *m, mbedtls_mpi_uint *p, diff --git a/library/bignum_mod_raw.h b/library/bignum_mod_raw.h index 8a202baa9..21743e0d0 100644 --- a/library/bignum_mod_raw.h +++ b/library/bignum_mod_raw.h @@ -17,8 +17,8 @@ * limitations under the License. */ -#ifndef MBEDTLS_BIGNUM_CORE_H -#define MBEDTLS_BIGNUM_CORE_H +#ifndef MBEDTLS_BIGNUM_MOD_RAW_H +#define MBEDTLS_BIGNUM_MOD_RAW_H #include "common.h" @@ -36,4 +36,4 @@ int mbedtls_mpi_mod_raw_write( mbedtls_mpi_uint *X, unsigned char *buf, size_t buflen ); -#endif /* MBEDTLS_BIGNUM_CORE_H */ +#endif /* MBEDTLS_BIGNUM_MOD_RAW_H */ diff --git a/library/bignum_new.c b/library/bignum_new.c index 976301d91..b6a806ecb 100644 --- a/library/bignum_new.c +++ b/library/bignum_new.c @@ -413,10 +413,10 @@ int mbedtls_mpi_mod_raw_read( mbedtls_mpi_uint *X, unsigned char *buf, size_t buflen ) { - if( m->ext_rep & MBEDTLS_MI_MOD_EXT_REP_LE ) + if( m->ext_rep & MBEDTLS_MPI_MOD_EXT_REP_LE ) return mbedtls_mpi_core_read_le( X, m->n, buf, buflen ); - else if( m->ext_rep & MBEDTLS_MI_MOD_EXT_REP_BE ) + else if( m->ext_rep & MBEDTLS_MPI_MOD_EXT_REP_BE ) return mbedtls_mpi_core_read_be( X, m->n, buf, buflen ); else @@ -430,10 +430,10 @@ int mbedtls_mpi_mod_raw_write( mbedtls_mpi_uint *X, unsigned char *buf, size_t buflen ) { - if( m->ext_rep & MBEDTLS_MI_MOD_EXT_REP_LE ) + if( m->ext_rep & MBEDTLS_MPI_MOD_EXT_REP_LE ) return mbedtls_mpi_core_write_le( X, m->n, buf, buflen ); - else if( m->ext_rep & MBEDTLS_MI_MOD_EXT_REP_BE ) + else if( m->ext_rep & MBEDTLS_MPI_MOD_EXT_REP_BE ) return mbedtls_mpi_core_write_be( X, m->n, buf, buflen ); else