fix buffer length for printing DFs

This commit is contained in:
Frank Morgner 2019-12-19 04:44:59 +01:00
parent b59456b6e4
commit 1cc6087126
1 changed files with 1 additions and 1 deletions

View File

@ -422,7 +422,7 @@ int sc_path_print(char *buf, size_t buflen, const sc_path_t *path)
if (buf == NULL || path == NULL)
return SC_ERROR_INVALID_ARGUMENTS;
if (buflen < path->len * 2 + path->aid.len * 2 + 1)
if (buflen < path->len * 2 + path->aid.len * 2 + 3)
return SC_ERROR_BUFFER_TOO_SMALL;
buf[0] = '\0';