Fix off-by-one
This commit is contained in:
parent
834a781112
commit
8bab691abc
1 changed files with 1 additions and 1 deletions
|
@ -210,7 +210,7 @@ void account_read_config_all(void)
|
||||||
while (fgets(buf, sizeof(buf), fp) != NULL) {
|
while (fgets(buf, sizeof(buf), fp) != NULL) {
|
||||||
if (!strncmp(buf, "[Account: ", 10)) {
|
if (!strncmp(buf, "[Account: ", 10)) {
|
||||||
strretchomp(buf);
|
strretchomp(buf);
|
||||||
memmove(buf, buf + 1, strlen(buf));
|
memmove(buf, buf + 1, strlen(buf) - 1);
|
||||||
buf[strlen(buf) - 1] = '\0';
|
buf[strlen(buf) - 1] = '\0';
|
||||||
debug_print("Found label: %s\n", buf);
|
debug_print("Found label: %s\n", buf);
|
||||||
ac_label_list = g_slist_append(ac_label_list,
|
ac_label_list = g_slist_append(ac_label_list,
|
||||||
|
|
Loading…
Reference in a new issue