bignum_mod: Renamed m -> N in mbedtls_mpi_mod_modulus_init()

Signed-off-by: Mihir Raj Singh <mihirrajsingh123@gmail.com>
This commit is contained in:
Mihir Raj Singh 2023-01-11 19:55:14 +05:30
parent b13a58938a
commit b6fa940fc4
2 changed files with 12 additions and 12 deletions

View File

@ -59,16 +59,16 @@ void mbedtls_mpi_mod_residue_release(mbedtls_mpi_mod_residue *r)
r->p = NULL; r->p = NULL;
} }
void mbedtls_mpi_mod_modulus_init(mbedtls_mpi_mod_modulus *m) void mbedtls_mpi_mod_modulus_init( mbedtls_mpi_mod_modulus *N )
{ {
if (m == NULL) { if (N == NULL) {
return; return;
} }
m->p = NULL; N->p = NULL;
m->limbs = 0; N->limbs = 0;
m->bits = 0; N->bits = 0;
m->int_rep = MBEDTLS_MPI_MOD_REP_INVALID; N->int_rep = MBEDTLS_MPI_MOD_REP_INVALID;
} }
void mbedtls_mpi_mod_modulus_free(mbedtls_mpi_mod_modulus *m) void mbedtls_mpi_mod_modulus_free(mbedtls_mpi_mod_modulus *m)

View File

@ -185,20 +185,20 @@ void mbedtls_mpi_mod_residue_release(mbedtls_mpi_mod_residue *r);
/** Initialize a modulus structure. /** Initialize a modulus structure.
* *
* \param[out] m The address of the modulus structure to initialize. * \param[out] N The address of the modulus structure to initialize.
*/ */
void mbedtls_mpi_mod_modulus_init(mbedtls_mpi_mod_modulus *m); void mbedtls_mpi_mod_modulus_init( mbedtls_mpi_mod_modulus *N );
/** Setup a modulus structure. /** Setup a modulus structure.
* *
* \param[out] m The address of the modulus structure to populate. * \param[out] N The address of the modulus structure to populate.
* \param[in] p The address of the limb array storing the value of \p m. * \param[in] p The address of the limb array storing the value of \p N.
* The memory pointed to by \p p will be used by \p m and must * The memory pointed to by \p p will be used by \p N and must
* not be modified in any way until after * not be modified in any way until after
* mbedtls_mpi_mod_modulus_free() is called. * mbedtls_mpi_mod_modulus_free() is called.
* \param p_limbs The number of limbs of \p p. * \param p_limbs The number of limbs of \p p.
* \param int_rep The internal representation to be used for residues * \param int_rep The internal representation to be used for residues
* associated with \p m (see #mbedtls_mpi_mod_rep_selector). * associated with \p N (see #mbedtls_mpi_mod_rep_selector).
* *
* \return \c 0 if successful. * \return \c 0 if successful.
* \return #MBEDTLS_ERR_MPI_BAD_INPUT_DATA if \p int_rep is invalid. * \return #MBEDTLS_ERR_MPI_BAD_INPUT_DATA if \p int_rep is invalid.