mirror of
https://git.suyu.dev/suyu/mbedtls.git
synced 2025-12-24 00:06:32 +01:00
Add mpi_shrink()
This commit is contained in:
parent
e282012219
commit
5868163e07
4 changed files with 90 additions and 0 deletions
|
|
@ -201,6 +201,17 @@ void mpi_free( mpi *X );
|
|||
*/
|
||||
int mpi_grow( mpi *X, size_t nblimbs );
|
||||
|
||||
/**
|
||||
* \brief Resize down, keeping at least the specified number of limbs
|
||||
*
|
||||
* \param X MPI to shrink
|
||||
* \param nblimbs The minimum number of limbs to keep
|
||||
*
|
||||
* \return 0 if successful,
|
||||
* POLARSSL_ERR_MPI_MALLOC_FAILED if memory allocation failed
|
||||
*/
|
||||
int mpi_shrink( mpi *X, size_t nblimbs );
|
||||
|
||||
/**
|
||||
* \brief Copy the contents of Y into X
|
||||
*
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue