Allow newlines in SUMMARY by replacing them with blanks

Addresses Github issue #414 (Android calendar allows them).

Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
This commit is contained in:
Lars Henriksen
2022-03-13 18:12:26 +01:00
committed by Lukas Fleischer
parent 01ad848628
commit ec38714bbc
2 changed files with 4 additions and 8 deletions

View File

@@ -1331,12 +1331,9 @@ static char *ical_read_summary(char *line, unsigned *noskipped,
}
/* An event summary is one line only. */
if (strchr(summary, '\n')) {
ical_log(log, item_type, itemline, _("line break in summary."));
(*noskipped)++;
mem_free(summary);
summary = NULL;
}
for (p = summary; *p; p++)
if (*p == '\n')
*p = ' ';
leave:
return summary;
}