Skip to content

Commit 02f8005

Browse files
committed
fixup! strbuf.c: add strbuf_join_argv()
In preparation for a newer patch series. Signed-off-by: Johannes Schindelin <[email protected]>
1 parent dd1d9a5 commit 02f8005

File tree

2 files changed

+0
-22
lines changed

2 files changed

+0
-22
lines changed

strbuf.c

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -268,21 +268,6 @@ void strbuf_addbuf(struct strbuf *sb, const struct strbuf *sb2)
268268
strbuf_setlen(sb, sb->len + sb2->len);
269269
}
270270

271-
const char *strbuf_join_argv(struct strbuf *buf,
272-
int argc, const char **argv, char delim)
273-
{
274-
if (!argc)
275-
return buf->buf;
276-
277-
strbuf_addstr(buf, *argv);
278-
while (--argc) {
279-
strbuf_addch(buf, delim);
280-
strbuf_addstr(buf, *(++argv));
281-
}
282-
283-
return buf->buf;
284-
}
285-
286271
void strbuf_addchars(struct strbuf *sb, int c, size_t n)
287272
{
288273
strbuf_grow(sb, n);

strbuf.h

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -288,13 +288,6 @@ static inline void strbuf_addstr(struct strbuf *sb, const char *s)
288288
*/
289289
void strbuf_addbuf(struct strbuf *sb, const struct strbuf *sb2);
290290

291-
/**
292-
* Join the arguments into a buffer. `delim` is put between every
293-
* two arguments.
294-
*/
295-
const char *strbuf_join_argv(struct strbuf *buf, int argc,
296-
const char **argv, char delim);
297-
298291
/**
299292
* This function can be used to expand a format string containing
300293
* placeholders. To that end, it parses the string and calls the specified

0 commit comments

Comments
 (0)