Merge remote-tracking branch 'upstream-public/pr/1932' into development

Resolve conflicts in programs/ssl/ssl_mail_client.c. PR #930 already had
the fix, but not the comment. PR #1932 then just adds a comment about the
fix.
This commit is contained in:
Jaeden Amero 2018-08-17 15:21:55 +01:00
commit d22c1b2445

View file

@ -358,7 +358,11 @@ int main( int argc, char *argv[] )
mbedtls_net_context server_fd; mbedtls_net_context server_fd;
#if defined(MBEDTLS_BASE64_C) #if defined(MBEDTLS_BASE64_C)
unsigned char base[1024]; unsigned char base[1024];
unsigned char buf[ sizeof( base ) + 2 ]; /* buf is used as the destination buffer for printing base with the format:
* "%s\r\n". Hence, the size of buf should be at least the size of base
* plus 2 bytes for the \r and \n characters.
*/
unsigned char buf[sizeof( base ) + 2];
#else #else
unsigned char buf[1024]; unsigned char buf[1024];
#endif #endif