/*
**********************************************************************
-* Copyright (c) 2003-2013, International Business Machines
+* Copyright (c) 2003-2014, International Business Machines
* Corporation and others. All Rights Reserved.
**********************************************************************
* Author: Alan Liu
}
// skip additional Olson byte version
file.read(buf, 1);
- // if '\0', we have just one copy of data, if '2', there is additional
+ // if '\0', we have just one copy of data, if '2' or '3', there is additional
// 64 bit version at the end.
- if(buf[0]!=0 && buf[0]!='2') {
+ if(buf[0]!=0 && buf[0]!='2' && buf[0]!='3') {
throw invalid_argument("Bad Olson version info");
}
<< " and rule ID " << ruleid;
throw invalid_argument(os.str());
}
- if (year < 1900 || year >= 2050) {
+ if (year < 1900) {
ostringstream os;
os << "Invalid input year " << year
<< " with offset " << offset
if (mode != DOM && (dow < 0 || dow >= 7)) {
os << "Invalid input day of week " << dow;
}
- if (offset < 0 || offset > HOUR) {
+ if (offset < 0 || offset > (2 * HOUR)) {
os << "Invalid input offset " << offset;
}
if (isgmt && !isstd) {
file << ", International Business Machines" << endl
<< "// Corporation and others. All Rights Reserved." << endl
<< "//---------------------------------------------------------" << endl
- << "// Build tool: tz2icu" << endl
- << "// Build date: " << asctime(now) /* << endl -- asctime emits CR */
- << "// Olson source: ftp://elsie.nci.nih.gov/pub/" << endl
- << "// Olson version: " << version << endl
+ << "// Build tool: tz2icu" << endl
+ << "// Build date: " << asctime(now) /* << endl -- asctime emits CR */
+ << "// tz database: ftp://ftp.iana.org/tz/" << endl
+ << "// tz version: " << version << endl
<< "// ICU version: " << U_ICU_VERSION << endl
<< "//---------------------------------------------------------" << endl
<< "// >> !!! >> THIS IS A MACHINE-GENERATED FILE << !!! <<" << endl