Made POLARSSL_MD_MAX_SIZE dependent on POLARSSL_SHA512_C

This commit is contained in:
Paul Bakker 2013-09-10 11:10:57 +02:00
parent 003dbad250
commit 7db0109436

View file

@ -60,7 +60,11 @@ typedef enum {
POLARSSL_MD_SHA512,
} md_type_t;
#if defined(POLARSSL_SHA512_C)
#define POLARSSL_MD_MAX_SIZE 64 /* longest known is SHA512 */
#else
#define POLARSSL_MD_MAX_SIZE 32 /* longest known is SHA256 or less */
#endif
/**
* Message digest information. Allows message digest functions to be called