Changeset 9012 for trunk/MagicSoft/Mars/mbase/MTime.cc
- Timestamp:
- 07/18/08 19:41:12 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mbase/MTime.cc
r8999 r9012 759 759 time.tm_mon = mon-1; 760 760 time.tm_year = y-1900; 761 time.tm_isdst = 0; 762 761 time.tm_isdst = -1; 762 763 // -1: If dst, isdst is set to 1 but hour is not changed 764 // 0: If dst, hour is changed 765 766 // Get old local 763 767 const TString locale = setlocale(LC_TIME, 0); 764 768 769 // Set new local (e.g. Montag instead of Monday) 765 770 setlocale(LC_TIME, loc); 766 771 767 772 // recalculate tm_yday and tm_wday 768 mktime(&time); 773 if (mktime(&time)<0) 774 return ""; 769 775 770 776 char ret[128];
Note:
See TracChangeset
for help on using the changeset viewer.