|
5346be3d
|
2021-09-23T21:16:36
|
|
docs: document `git_buf`
We have been inconsistent about the way that we handle `git_buf`s
provided by users. _Usually_ we require that it has been properly
initialized with `GIT_BUF_INIT`, but _sometimes_ we simply overwrite
the data in it regardless. And even more rarely, we will grow a
user-provided buffer and concatenate data onto it (see
`git_diff_format_email`).
Document the path forward for `git_buf`, which is that we always
require that the buffer is intitialized with `GIT_BUF_INIT`.
`git_diff_format_email` will be kept backward compatible but users
are encouraged to switch to the new `git_email` APIs.
|