summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 6bd22bd)
raw | patch | inline | side by side (parent: 6bd22bd)
author | Max Kellermann <max@duempel.org> | |
Sun, 18 Oct 2009 18:35:59 +0000 (20:35 +0200) | ||
committer | Max Kellermann <max@duempel.org> | |
Sun, 18 Oct 2009 18:35:59 +0000 (20:35 +0200) |
src/hscroll.c | patch | blob | history |
diff --git a/src/hscroll.c b/src/hscroll.c
index 00bda797a70e60d5c312f6391564e7c389e838d5..481683c847a8f490820a8b6b7991a3e045c45d21 100644 (file)
--- a/src/hscroll.c
+++ b/src/hscroll.c
return g_strdup(str);
/* create a buffer containing the string and the separator */
- size = strlen(str)+strlen(separator)+1;
- tmp = g_malloc(size);
- g_strlcpy(tmp, str, size);
- g_strlcat(tmp, separator, size);
+ tmp = g_strconcat(str, separator, NULL);
len = utf8_width(tmp);
if (hscroll->offset >= len)