summaryrefslogtreecommitdiff
path: root/mail/dbmail22/files/patch-2.0.7_005_277
diff options
context:
space:
mode:
authorPav Lucistnik <pav@FreeBSD.org>2005-11-15 00:10:58 +0000
committerPav Lucistnik <pav@FreeBSD.org>2005-11-15 00:10:58 +0000
commitefc03a7db42e86c5b41383ebda01bbbb4fcab4e8 (patch)
treecc2c75a3105316183ad3858c5730546d9428a621 /mail/dbmail22/files/patch-2.0.7_005_277
parent- Update to 0.4.6 (diff)
- Integrate vendor patches:
1. #266 - Excessive db connects and quits 2. #271 - BUG with connect to postgresql database 3. #272 - Non-UTF characters in a message's body 4. #277 - Fix "INTERNALDATE" calculation in imaputil.c 5. other patches from repository. - Add SHA256 PR: ports/88277 Submitted by: Mark Starovoytov <mark_sf@kikg.ifmo.ru> (maintainer)
Diffstat (limited to 'mail/dbmail22/files/patch-2.0.7_005_277')
-rw-r--r--mail/dbmail22/files/patch-2.0.7_005_27738
1 files changed, 38 insertions, 0 deletions
diff --git a/mail/dbmail22/files/patch-2.0.7_005_277 b/mail/dbmail22/files/patch-2.0.7_005_277
new file mode 100644
index 000000000000..b659de88aac4
--- /dev/null
+++ b/mail/dbmail22/files/patch-2.0.7_005_277
@@ -0,0 +1,38 @@
+--- imapcommands.c (revision 1904)
++++ imapcommands.c (revision 1905)
+@@ -1787,6 +1787,8 @@
+ if (args[i + 1]) {
+ struct tm tm;
+
++ memset(&tm, 0, sizeof(struct tm));
++
+ if (strptime(args[i], "%d-%b-%Y %T", &tm) != NULL)
+ strftime(sqldate,
+ sizeof(sqldate), "%Y-%m-%d %H:%M:%S",
+--- imaputil.c (revision 1904)
++++ imaputil.c (revision 1905)
+@@ -1788,13 +1788,14 @@
+ time_t ltime;
+ char *last;
+
++ memset(&tm_sql_date, 0, sizeof(struct tm));
++
+ last = strptime(sqldate,"%Y-%m-%d %T", &tm_sql_date);
+ if ( (last == NULL) || (*last != '\0') ) {
+ strcpy(_imapdate, IMAP_STANDARD_DATE);
+ return _imapdate;
+ }
+
+- /* FIXME: this works fine on linux, but may cause dst offsets in netbsd. */
+ ltime = mktime (&tm_sql_date);
+ tm_imap_date = localtime(&ltime);
+
+@@ -1814,6 +1815,8 @@
+ struct tm tm;
+ char *last_char;
+
++ memset(&tm, 0, sizeof(struct tm));
++
+ last_char = strptime(imapdate, "%d-%b-%Y", &tm);
+ if (last_char == NULL || *last_char != '\0') {
+ trace(TRACE_DEBUG, "%s,%s: error parsing IMAP date %s",