aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorLars Henriksen <LarsHenriksen@get2net.dk>2019-02-14 09:54:54 +0100
committerLukas Fleischer <lfleischer@calcurse.org>2019-02-28 08:02:35 +0100
commita47a562322d52275b0bae7181a5077cf95b24ffb (patch)
tree4a9ae23bfc82c94c1f7801e2bf3f9bd3d7384144 /src
parent90b91d92dbb259e5195f5a45b015ae73875f97e3 (diff)
downloadcalcurse-a47a562322d52275b0bae7181a5077cf95b24ffb.tar.gz
calcurse-a47a562322d52275b0bae7181a5077cf95b24ffb.zip
Fix empty dynamic string
Signed-off-by: Lars Henriksen <LarsHenriksen@get2net.dk> Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
Diffstat (limited to 'src')
-rw-r--r--src/strings.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/strings.c b/src/strings.c
index 6601a99..a84f836 100644
--- a/src/strings.c
+++ b/src/strings.c
@@ -45,6 +45,7 @@ void string_init(struct string *sb)
sb->buf = mem_malloc(STRING_INITIAL_BUFSIZE);
sb->bufsize = STRING_INITIAL_BUFSIZE;
sb->len = 0;
+ *sb->buf = '\0';
}
void string_reset(struct string *sb)