ruby-changes:21636
From: usa <ko1@a...>
Date: Wed, 9 Nov 2011 16:43:22 +0900 (JST)
Subject: [ruby-changes:21636] usa:r33685 (trunk): * win32/win32.c (unixtime_to_filetime): should check the return value
usa 2011-11-09 16:43:08 +0900 (Wed, 09 Nov 2011) New Revision: 33685 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=33685 Log: * win32/win32.c (unixtime_to_filetime): should check the return value of localtime(). reported by snowjail at gmail.com. [ruby-dev:44838] [Bug #5596] Modified files: trunk/ChangeLog trunk/win32/win32.c Index: ChangeLog =================================================================== --- ChangeLog (revision 33684) +++ ChangeLog (revision 33685) @@ -1,3 +1,9 @@ +Wed Nov 9 16:40:49 2011 NAKAMURA Usaku <usa@r...> + + * win32/win32.c (unixtime_to_filetime): should check the return value + of localtime(). reported by snowjail at gmail.com. + [ruby-dev:44838] [Bug #5596] + Thu Nov 10 05:17:25 2011 Koichi Sasada <ko1@a...> * cont.c (rb_fiber_m_transfer, rb_fiber_resume): prohibit using Index: win32/win32.c =================================================================== --- win32/win32.c (revision 33684) +++ win32/win32.c (revision 33685) @@ -5758,6 +5758,9 @@ FILETIME lt; tm = localtime(&time); + if (!tm) { + return -1; + } st.wYear = tm->tm_year + 1900; st.wMonth = tm->tm_mon + 1; st.wDayOfWeek = tm->tm_wday; -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/