Merge pull request #8234 from kouzhudong/development

Fix MSVC error C4703 about possibly uninitialized variable in pkwrite.c
This commit is contained in:
Dave Rodgman 2023-09-25 10:51:46 +01:00 committed by GitHub
commit 5a3add2c67
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -379,7 +379,7 @@ int mbedtls_pk_write_pubkey_der(const mbedtls_pk_context *key, unsigned char *bu
#if defined(MBEDTLS_PK_HAVE_ECC_KEYS)
mbedtls_ecp_group_id ec_grp_id = MBEDTLS_ECP_DP_NONE;
#endif
const char *oid;
const char *oid = NULL;
if (size == 0) {
return MBEDTLS_ERR_ASN1_BUF_TOO_SMALL;