[evolution-patches] fix for bug #49357 (timezone out of bounds fix)



timezone offsets range from -1200 to +1400, but if the timezone offset
was > +1200, we set it back to 0.

attached patch fixes that.

-- 
Jeffrey Stedfast
Evolution Hacker - Ximian, Inc.
fejj ximian com  - www.ximian.com
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/evolution/camel/ChangeLog,v
retrieving revision 1.1836.2.15
diff -u -r1.1836.2.15 ChangeLog
--- ChangeLog	26 Sep 2003 16:04:48 -0000	1.1836.2.15
+++ ChangeLog	8 Oct 2003 16:42:50 -0000
@@ -1,3 +1,8 @@
+2003-10-08  Jeffrey Stedfast  <fejj ximian com>
+
+	* camel-mime-utils.c (header_decode_date): Allow timezone offsets
+	to be up to 14 hours ahead of UTC. Fixes bug #49357.
+
 2003-09-25  Jeffrey Stedfast  <fejj ximian com>
 
 	* providers/smtp/camel-smtp-transport.c (smtp_helo): If the
Index: camel-mime-utils.c
===================================================================
RCS file: /cvs/gnome/evolution/camel/camel-mime-utils.c,v
retrieving revision 1.183.4.4
diff -u -r1.183.4.4 camel-mime-utils.c
--- camel-mime-utils.c	26 Sep 2003 16:04:49 -0000	1.183.4.4
+++ camel-mime-utils.c	8 Oct 2003 16:42:55 -0000
@@ -3530,12 +3530,12 @@
 		offset = (*inptr++)=='-'?-1:1;
 		offset = offset * header_decode_int(&inptr);
 		d(printf("abs signed offset = %d\n", offset));
-		if (offset < -1200 || offset > 1200)
+		if (offset < -1200 || offset > 1400)
 			offset = 0;
 	} else if (isdigit(*inptr)) {
 		offset = header_decode_int(&inptr);
 		d(printf("abs offset = %d\n", offset));
-		if (offset < -1200 || offset > 1200)
+		if (offset < -1200 || offset > 1400)
 			offset = 0;
 	} else {
 		char *tz = decode_token(&inptr);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]