]> git.pld-linux.org Git - packages/imap.git/blame - imap-overflow.patch
- rediff patches, rebuild with openssl 3.0.0, rel 8
[packages/imap.git] / imap-overflow.patch
CommitLineData
b15f5ef7
JR
1diff -urNp -x '*.orig' imap-2007f.org/src/c-client/rfc822.c imap-2007f/src/c-client/rfc822.c
2--- imap-2007f.org/src/c-client/rfc822.c 2011-07-23 02:20:18.000000000 +0200
3+++ imap-2007f/src/c-client/rfc822.c 2021-09-29 21:57:47.019342032 +0200
4@@ -384,6 +384,9 @@ void rfc822_parse_content (BODY *body,ST
696e857c
JB
5 if (CHR (bs) == '\012'){/* following LF? */
6 c = SNX (bs); i--; /* yes, slurp it */
7 }
8+ if (!i) /* Make sure we don't get an overflow for */
9+ break; /* messages ending on \015 (or the following */
10+ /* i-- will cause i to be MAXINT. Not good.) */
11 case '\012': /* at start of a line, start with -- ? */
b15f5ef7
JR
12 if (!(i && i-- && ((c = SNX (bs)) == '-') && i-- &&
13 ((c = SNX (bs)) == '-'))) break;
This page took 0.074284 seconds and 4 git commands to generate.