Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/libgit2.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRussell Belfer <arrbee@arrbee.com>2011-11-28 22:42:57 +0400
committerRussell Belfer <arrbee@arrbee.com>2011-11-28 22:42:57 +0400
commit3aa294fd450873eaef85ecadaab086b414c4e07e (patch)
tree69a80902eb56fe419f0a445f3f569cfa35d61532 /src/buffer.h
parent8c74d22ebfae33323b5561d9bd988f272ff61a01 (diff)
Add two string git_buf_join and tweak input error checking.
This commit addresses two of the comments: * renamed existing n-input git_buf_join to git_buf_join_n * added new git_buf_join that always takes two inputs * moved some parameter error checking to asserts * extended unit tests to cover new version of git_buf_join
Diffstat (limited to 'src/buffer.h')
-rw-r--r--src/buffer.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/buffer.h b/src/buffer.h
index baa8f4f4d..2ed9047ca 100644
--- a/src/buffer.h
+++ b/src/buffer.h
@@ -37,7 +37,8 @@ void git_buf_puts(git_buf *buf, const char *string);
void git_buf_printf(git_buf *buf, const char *format, ...) GIT_FORMAT_PRINTF(2, 3);
void git_buf_clear(git_buf *buf);
void git_buf_consume(git_buf *buf, const char *end);
-void git_buf_join(git_buf *buf, char separator, int nbuf, ...);
+void git_buf_join_n(git_buf *buf, char separator, int nbuf, ...);
+void git_buf_join(git_buf *buf, char separator, const char *str_a, const char *str_b);
const char *git_buf_cstr(git_buf *buf);
char *git_buf_take_cstr(git_buf *buf);