diff --git a/library/x509_crt.c b/library/x509_crt.c index 9251aed31..81402ba55 100644 --- a/library/x509_crt.c +++ b/library/x509_crt.c @@ -1121,7 +1121,7 @@ int mbedtls_x509_crt_parse_path( mbedtls_x509_crt *chain, const char *path ) p = filename + len; filename[len++] = '*'; - w_ret = MultiByteToWideChar( CP_ACP, 0, filename, len, szDir, + w_ret = MultiByteToWideChar( CP_ACP, 0, filename, (int)len, szDir, MAX_PATH - 3 ); if( w_ret == 0 ) return( MBEDTLS_ERR_X509_BAD_INPUT_DATA );