x509_crt: Adjusted the len of lpMultiByteStr arg in WideCharToMultiByte
Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
This commit is contained in:
parent
08a67ccefd
commit
59108d3f4d
1 changed files with 1 additions and 2 deletions
|
@ -1585,8 +1585,7 @@ int mbedtls_x509_crt_parse_path(mbedtls_x509_crt *chain, const char *path)
|
|||
continue;
|
||||
}
|
||||
w_ret = WideCharToMultiByte(CP_ACP, 0, file_data.cFileName,
|
||||
-1, p, (int) len - 1,
|
||||
NULL, NULL);
|
||||
-1, p, (int) len, NULL, NULL);
|
||||
if (w_ret == 0) {
|
||||
ret = MBEDTLS_ERR_X509_FILE_IO_ERROR;
|
||||
goto cleanup;
|
||||
|
|
Loading…
Reference in a new issue