http://d.puremagic.com/issues/show_bug.cgi?id=5552
Summary: std.datetime.d DosFileTimeToSysTime has a bug Product: D Version: D2 Platform: Other OS/Version: Windows Status: NEW Severity: normal Priority: P2 Component: Phobos AssignedTo: nob...@puremagic.com ReportedBy: soar...@yeah.net --- Comment #0 from soar...@yeah.net 2011-02-08 18:49:15 PST --- import std.datetime, std.stdio; void main() { auto time = cast(DosFileTime)0x3E3F8456; writeln(DosFileTimeToSysTime(time)); //output should: 2011-Jan-31 16:34:44 } Compile and run above snipplet, will get an exception. Solution: change std.datetime.d at line 31820 from int month = ((dt >> 21) & 0x0F) - 1; // 1..12 to int month = ((dt >> 21) & 0x0F); // 1..12 -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------