Add mpi_shrink()
diff --git a/include/polarssl/bignum.h b/include/polarssl/bignum.h
index 9bed027..1052c5a 100644
--- a/include/polarssl/bignum.h
+++ b/include/polarssl/bignum.h
@@ -202,6 +202,17 @@
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
*
* \param X Destination MPI