(strptime_internal): In %y format, regard years >= 69 as of twentieth
authordrepper <drepper>
Fri, 31 Oct 1997 22:54:24 +0000 (22:54 +0000)
committerdrepper <drepper>
Fri, 31 Oct 1997 22:54:24 +0000 (22:54 +0000)
century, all other as of twenty-first.

time/strptime.c

index 4e91a71..30b0156 100644 (file)
@@ -543,7 +543,9 @@ strptime_internal (buf, format, tm, decided)
        case 'y':
          /* Match year within century.  */
          get_number (0, 99);
-         tm->tm_year = val >= 50 ? val : val + 100;
+         /* The "Year 2000 :The Millennium Rollover" paper suggests that
+            values in the range 69-99 refer to the twentieth century.  */
+         tm->tm_year = val >= 69 ? val : val + 100;
          break;
        case 'Y':
          /* Match year including century number.  */