summaryrefslogtreecommitdiff
path: root/mail/popper/files/patch-an
diff options
context:
space:
mode:
authorAndrey A. Chernov <ache@FreeBSD.org>2000-04-17 19:35:40 +0000
committerAndrey A. Chernov <ache@FreeBSD.org>2000-04-17 19:35:40 +0000
commitf13ab6a55c8a245ce1e8febbc1d7806eb047b7aa (patch)
tree995a481f10803e2be279efd5305a35cc49bd208e /mail/popper/files/patch-an
parentadd (diff)
1) Popper always assume that fgets got whole line, so it is easy to make
fake headers by special long lines aligned to buffer boundary - popper treat them as separate lines. Whole code needs rewriting. As workaround increase MAXLINE to the value sendmail use, hoping sendmail itself not makes longer lines. 2) Fix EUIDL responses not properly \n terminated.
Diffstat (limited to '')
-rw-r--r--mail/popper/files/patch-an28
1 files changed, 28 insertions, 0 deletions
diff --git a/mail/popper/files/patch-an b/mail/popper/files/patch-an
new file mode 100644
index 000000000000..e255bf9046f5
--- /dev/null
+++ b/mail/popper/files/patch-an
@@ -0,0 +1,28 @@
+--- pop_uidl.c.old Fri Jul 10 03:44:08 1998
++++ pop_uidl.c Mon Apr 17 22:56:13 2000
+@@ -98,6 +98,7 @@
+ {
+ static char buf[MAXLINELEN];
+ char *cp;
++ char *bp;
+
+ fseek(p->drop, mp->offset, 0);
+ while (fgets(buf, sizeof(buf), p->drop) != NULL) {
+@@ -105,6 +106,8 @@
+ if (!strncasecmp("From:", buf, 5)) {
+ cp = index(buf, ':');
+ while (*++cp && (*cp == ' ' || *cp == '\t'));
++ if ((bp = index(cp, NEWLINE)) != NULL)
++ *bp = 0;
+ return(cp);
+ }
+ }
+@@ -165,7 +168,7 @@
+
+ sprintf(buffer, "%d %s", x, mp->uidl_str);
+ if (nl = index(buffer, NEWLINE)) *nl = 0;
+- sprintf(buffer, "%s %d %.128s", buffer, mp->length, from_hdr(p, mp));
++ sprintf(buffer, "%s %d %.128s\n", buffer, mp->length, from_hdr(p, mp));
+ pop_sendline(p, buffer);
+ }
+ }