summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEduardo Chappa <chappa@washington.edu>2018-08-22 21:53:46 -0600
committerEduardo Chappa <chappa@washington.edu>2018-08-22 21:53:46 -0600
commitf801c074d043f7b8459a44c1061de39c5cdeeabb (patch)
treefd9425ce8f7064cb317a7c6622fd5367dbe1c350
parent8dc90e0f6aada498ae26b691ec7e6158a741cd2e (diff)
downloadalpine-f801c074d043f7b8459a44c1061de39c5cdeeabb.tar.xz
* Make sure that the Summary: entry in a calendar entry always gets
decoded with escapes removed. Similarly do the same for other headers.
-rw-r--r--alpine/mailpart.c1
-rw-r--r--pith/ical.c8
-rw-r--r--pith/mailview.c1
3 files changed, 6 insertions, 4 deletions
diff --git a/alpine/mailpart.c b/alpine/mailpart.c
index 68c69b9e..061ca5e2 100644
--- a/alpine/mailpart.c
+++ b/alpine/mailpart.c
@@ -2975,7 +2975,6 @@ display_vevent_summary(long int msgno, ATTACH_S *a, int flags, int depth)
}
if(vesy->location){
- ical_remove_escapes(&vesy->location);
utf8_snprintf(tmp_20k_buf, SIZEOF_20KBUF, "%s%s",
_("Location: "), vesy->location);
so_puts(in_store, tmp_20k_buf);
diff --git a/pith/ical.c b/pith/ical.c
index cff1f542..950f4018 100644
--- a/pith/ical.c
+++ b/pith/ical.c
@@ -2201,8 +2201,10 @@ ical_vevent_summary(VCALENDAR_S *vcal)
if((icl = (ICLINE_S *) vevent->prop[EvPriority]) != NULL)
rv->priority = atoi(icl->value);
- if((icl = (ICLINE_S *) vevent->prop[EvSummary]) != NULL)
+ if((icl = (ICLINE_S *) vevent->prop[EvSummary]) != NULL){
rv->summary = cpystr(icl->value ? icl->value : _("No Summary"));
+ ical_remove_escapes(&rv->summary);
+ }
if((icl = (ICLINE_S *) vevent->prop[EvClass]) != NULL)
rv->class = cpystr(icl->value ? icl->value : _("PUBLIC"));
@@ -2237,8 +2239,10 @@ ical_vevent_summary(VCALENDAR_S *vcal)
}
} /* end of if(organizer) */
- if((icl = (ICLINE_S *) vevent->prop[EvLocation]) != NULL)
+ if((icl = (ICLINE_S *) vevent->prop[EvLocation]) != NULL){
rv->location = cpystr(icl->value ? icl->value : _("Location undisclosed"));
+ ical_remove_escapes(&rv->location);
+ }
if((icl = (ICLINE_S *) vevent->prop[EvDtstart]) != NULL){
struct tm ic_date;
diff --git a/pith/mailview.c b/pith/mailview.c
index a0aead24..79f6e882 100644
--- a/pith/mailview.c
+++ b/pith/mailview.c
@@ -333,7 +333,6 @@ format_calendar_vevent(VCALENDAR_S *vcal, ATTACH_S *a, HANDLE_S **handlesp, int
} /* end of if(organizer) */
if(vesy->location){
- ical_remove_escapes(&vesy->location);
utf8_snprintf(tmp_20k_buf, SIZEOF_20KBUF, "%s%s%s",
padding, _("Location: "), vesy->location);
gf_puts(tmp_20k_buf, pc);