mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-08 22:45:43 +00:00
20 lines
634 B
Diff
20 lines
634 B
Diff
--- alpine-2.00/imap/src/c-client/rfc822.c
|
|
+++ alpine-2.00/imap/src/c-client/rfc822.c
|
|
@@ -1351,6 +1351,7 @@
|
|
|
|
static long rfc822_output_char (RFC822BUFFER *buf,int c)
|
|
{
|
|
+ if ((buf->cur == buf->end) && !rfc822_output_flush (buf)) return NIL;
|
|
*buf->cur++ = c; /* add character, soutr buffer if full */
|
|
return (buf->cur == buf->end) ? rfc822_output_flush (buf) : LONGT;
|
|
}
|
|
@@ -1374,7 +1375,8 @@
|
|
len -= i;
|
|
}
|
|
/* soutr buffer now if full */
|
|
- if (len && !rfc822_output_flush (buf)) return NIL;
|
|
+ if ((len || (buf->cur == buf->end)) && !rfc822_output_flush (buf))
|
|
+ return NIL;
|
|
}
|
|
return LONGT;
|
|
}
|