Author: ache
Date: Tue Oct  7 06:02:08 2014
New Revision: 272678
URL: https://svnweb.freebsd.org/changeset/base/272678

Log:
  Back out timegm error check from r272562.
  
  POSIX treats negative time_t as undefined (i.e. may be valid too,
  depends on system's policy we don't have) and we don't set EOVERFLOW
  in mktime/timegm as POSIX requires to surely distinguish -1 return
  as valid negative time from -1 as error return.

Modified:
  head/lib/libc/stdtime/strptime.c

Modified: head/lib/libc/stdtime/strptime.c
==============================================================================
--- head/lib/libc/stdtime/strptime.c    Tue Oct  7 06:00:32 2014        
(r272677)
+++ head/lib/libc/stdtime/strptime.c    Tue Oct  7 06:02:08 2014        
(r272678)
@@ -676,8 +676,6 @@ strptime_l(const char * __restrict buf, 
        if (ret && gmt) {
                time_t t = timegm(tm);
 
-               if (t == -1)
-                       return (NULL);
                localtime_r(&t, tm);
        }
 
_______________________________________________
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to