summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEduardo Chappa <chappa@washington.edu>2018-12-21 19:28:41 -0700
committerEduardo Chappa <chappa@washington.edu>2018-12-21 19:28:41 -0700
commit3be2ba48af54614d8e46ed9a26d7d76ecbef4808 (patch)
treee6bcbdd66ce261121b6ca0f9fdcee084925e3628
parent08d6d80b7cd3cccb32a81d91c481bbde938f4689 (diff)
downloadalpine-3be2ba48af54614d8e46ed9a26d7d76ecbef4808.tar.xz
* When we display a message/rfc822 attachment, print an error message
when there was an error fetching the body of that message.
-rw-r--r--alpine/mailpart.c18
1 files changed, 15 insertions, 3 deletions
diff --git a/alpine/mailpart.c b/alpine/mailpart.c
index 74f84ad..c1c8101 100644
--- a/alpine/mailpart.c
+++ b/alpine/mailpart.c
@@ -2726,8 +2726,12 @@ format_msg_att(long int msgno, ATTACH_S **a, HANDLE_S **handlesp, gf_io_t pc, in
if(((*a)+1)->description)
++(*a);
- else
+ else{
+ if(!(gf_puts("[Can't display missing text segment]", pc)
+ && gf_puts(NEWLINE, pc)))
+ rv = 0;
return rv;
+ }
#ifdef SMIME
if((*a)->body && (*a)->body->subtype && (strucmp((*a)->body->subtype, OUR_PKCS7_ENCLOSURE_SUBTYPE)==0)){
@@ -2741,8 +2745,12 @@ format_msg_att(long int msgno, ATTACH_S **a, HANDLE_S **handlesp, gf_io_t pc, in
if(((*a)+1)->description)
++(*a);
- else
+ else{
+ if(!(gf_puts("[Can't display missing text segment]", pc)
+ && gf_puts(NEWLINE, pc)))
+ rv = 0;
return rv;
+ }
}
#endif /* SMIME */
@@ -2760,8 +2768,12 @@ format_msg_att(long int msgno, ATTACH_S **a, HANDLE_S **handlesp, gf_io_t pc, in
if(((*a)+1)->description)
++(*a);
- else
+ else{
+ if(!(gf_puts("[Can't display missing text segment]", pc)
+ && gf_puts(NEWLINE, pc)))
+ rv = 0;
return rv;
+ }
}
else if((*a)->body->subtype