Use plain memset() for freshly allocated objects
This commits reverts to plain memset() for cases like:
some_type foo;
memset( &foo, 0, sizeof( foo ) );
(Sometimes there is code between declaration in memset(), but it doesn't
matter as long as it doesn't touch foo.)
The reasoning is the same as in the previous commit: the stack shouldn't
contain sensitive data as we carefully wipe it after use.
diff --git a/library/x509.c b/library/x509.c
index 33dc0b9..4b34486 100644
--- a/library/x509.c
+++ b/library/x509.c
@@ -943,7 +943,7 @@
const char *short_name = NULL;
char s[MBEDTLS_X509_MAX_DN_NAME_SIZE], *p;
- mbedtls_platform_memset( s, 0, sizeof( s ) );
+ memset( s, 0, sizeof( s ) );
name = dn;
p = buf;