{{ message }}
Repository navigation
Commit dc851d9
committed
commit: clear user-provided buffers
The functions `git_commit_header_field` and
`git_commit_extract_signature` both receive buffers used to hand back
the results to the user. While these functions called `git_buf_sanitize`
on these buffers, this is not the right thing to do, as it will simply
initialize or zero-terminate passed buffers. As we want to overwrite
contents, we instead have to call `git_buf_clear` to completely reset
them.1 parent cdb2c2a commit dc851d9
2 files changed
Lines changed: 9 additions & 6 deletions

0 commit comments