Commit 24cce239 by Vicent Marti

text: Null-terminate a string if we've been gouging it

parent b7fb71e3
......@@ -143,6 +143,7 @@ int git_buf_text_lf_to_crlf(git_buf *tgt, const git_buf *src)
tgt->ptr[tgt->size++] = '\n';
}
tgt->ptr[tgt->size] = '\0';
return git_buf_put(tgt, scan, end - scan);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment