[Mono-bugs] [Bug 49502][Maj] New - System.DateTime.MaxValue returns a value that is not a valid DateTime

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Thu, 9 Oct 2003 19:12:57 -0400 (EDT)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by chris@turchin.net.

http://bugzilla.ximian.com/show_bug.cgi?id=49502

--- shadow/49502	2003-10-09 19:12:57.000000000 -0400
+++ shadow/49502.tmp.6618	2003-10-09 19:12:57.000000000 -0400
@@ -0,0 +1,51 @@
+Bug#: 49502
+Product: Mono/Class Libraries
+Version: unspecified
+OS: Mandrake 9.1
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Major
+Component: CORLIB
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: chris@turchin.net               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: System.DateTime.MaxValue returns a value that is not a valid DateTime
+
+Please fill in this template when reporting a bug, unless you know what you
+are doing.
+Description of Problem:
+ System.DateTime.MaxValue returns a value that is not a valid DateTime
+
+Steps to reproduce the problem:
+DateTime dt  = DateTime.MaxValue;
+DateTime dt2 = new DateTime(dt.Year,dt.Month,dt.Day);
+
+Actual Results:
+Unhandled Exception: System.ArgumentOutOfRangeException: 29228 is not in a
+range
+ between 1 and 9999.
+Parameter name: year
+in <0x0009d> System.CurrentTimeZone:GetDaylightChanges (int)
+in <0x00046> System.TimeZone:IsDaylightSavingTime (System.DateTime)
+in <0x0001e> System.CurrentTimeZone:GetUtcOffset (System.DateTime)
+in <0x000cd> System.DateTime:_ToString
+(string,System.Globalization.DateTimeForm
+atInfo)
+in <0x00106> System.DateTime:ToString (string,System.IFormatProvider)
+in <0x00017> System.DateTime:ToString ()
+in <0x00030> .Test:Main (string[])
+
+
+Expected Results:
+No Exception would be nice...
+
+How often does this happen? 
+whenever i try...
+
+Additional Information:
+will attach patch...