diff options
author | Thierry Thomas <thierry@FreeBSD.org> | 2014-12-14 17:56:14 +0000 |
---|---|---|
committer | Thierry Thomas <thierry@FreeBSD.org> | 2014-12-14 17:56:14 +0000 |
commit | 69d0a0a2587baa86415d5b3cdc6a59afa7ae2ca1 (patch) | |
tree | 04a33ff4ac942f99bcc586ad49b302bf830b43bf /mail/panda-imap/files/patch-src_mtest_mtest.c | |
parent | - Install missing file latency.txt (diff) |
Adding mail/panda-cclient and mail/panda-imap.
Since Mark Crispin left the UW, development on UW-IMAP paused. Mark
however continued developing the toolkit under the name Panda-IMAP.
Since Mark passed, Jonathan Abbey created a project on GitHub, by
concatenating all of the public releases of UW IMAP with the last
version of Panda IMAP.
Add conflict lines with the original ports.
Notes
Notes:
svn path=/head/; revision=374717
Diffstat (limited to 'mail/panda-imap/files/patch-src_mtest_mtest.c')
-rw-r--r-- | mail/panda-imap/files/patch-src_mtest_mtest.c | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/mail/panda-imap/files/patch-src_mtest_mtest.c b/mail/panda-imap/files/patch-src_mtest_mtest.c new file mode 100644 index 000000000000..a3b490909a09 --- /dev/null +++ b/mail/panda-imap/files/patch-src_mtest_mtest.c @@ -0,0 +1,47 @@ +--- src/mtest/mtest.c.orig Sat May 29 08:07:06 1999 ++++ src/mtest/mtest.c Sun Dec 19 15:29:29 1999 +@@ -95,6 +95,7 @@ + void status (MAILSTREAM *stream); + void prompt (char *msg,char *txt); + void smtptest (long debug); ++char *safegets(char *buf); + + /* Main program - initialization */ + +@@ -528,7 +529,7 @@ + void prompt (char *msg,char *txt) + { + printf ("%s",msg); +- gets (txt); ++ safegets (txt); + } + + /* Interfaces to C-client */ +@@ -713,7 +714,7 @@ + puts (" Msg (end with a line with only a '.'):"); + body->type = TYPETEXT; + *text = '\0'; +- while (gets (line)) { ++ while (safegets (line)) { + if (line[0] == '.') { + if (line[1] == '\0') break; + else strcat (text,"."); +@@ -744,4 +745,18 @@ + else puts ("[Can't open connection to any server]"); + mail_free_envelope (&msg); + mail_free_body (&body); ++} ++ ++char *safegets(char *buf) { ++ char *p; ++ ++ if (!fgets(buf, MAILTMPLEN, stdin)) { ++ return NULL; ++ } ++ ++ if ((p = strchr(buf, '\n')) != NULL) { ++ *p = '\0'; ++ } ++ ++ return buf; + } |