patch-localtime_c 970 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. --- w-tzdata-2014d-1.orig/localtime.c 2014-01-18 07:42:22.000000000 +0100
  2. +++ w-tzdata-2014d-1/localtime.c 2014-05-30 09:09:35.130879741 +0200
  3. @@ -1329,7 +1329,7 @@ localsub(const time_t *const timep, cons
  4. }
  5. struct tm *
  6. -localtime(const time_t *const timep)
  7. +localtime_tz(const time_t *const timep)
  8. {
  9. tzset();
  10. return localsub(timep, 0L, &tm);
  11. @@ -1550,7 +1550,7 @@ ctime(const time_t *const timep)
  12. ** to local time in the form of a string. It is equivalent to
  13. ** asctime(localtime(timer))
  14. */
  15. - return asctime(localtime(timep));
  16. + return asctime(localtime_tz(timep));
  17. }
  18. char *
  19. @@ -1929,7 +1929,7 @@ time1(struct tm *const tmp,
  20. }
  21. time_t
  22. -mktime(struct tm *const tmp)
  23. +mktime_tz(struct tm *const tmp)
  24. {
  25. tzset();
  26. return time1(tmp, localsub, 0L);
  27. @@ -1973,7 +1973,7 @@ timeoff(struct tm *const tmp, const long
  28. long
  29. gtime(struct tm *const tmp)
  30. {
  31. - const time_t t = mktime(tmp);
  32. + const time_t t = mktime_tz(tmp);
  33. if (t == WRONG)
  34. return -1;