Skip to content

Commit

Permalink
strbuf: init empty
Browse files Browse the repository at this point in the history
  • Loading branch information
lemonsqueeze committed Jul 14, 2018
1 parent 527a8b8 commit d06780c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions util.c
Expand Up @@ -154,6 +154,7 @@ strbuf_t *
strbuf_init(strbuf_t *buf, char *buffer, int size)
{
buf->str = buf->cur = buffer;
buf->str[0] = 0;
buf->remaining = size;
return buf;
}
Expand Down

0 comments on commit d06780c

Please sign in to comment.