提交 aed8eb8c 编写于 作者: P peytoia

7090844: Support a timezone whose offset is changed more than once in the future

Reviewed-by: okutsu
上级 b24f62f2
...@@ -76,8 +76,8 @@ class Mappings { ...@@ -76,8 +76,8 @@ class Mappings {
// If the GMT offset of this Zone will change in some // If the GMT offset of this Zone will change in some
// future time, this Zone is added to the exclude list. // future time, this Zone is added to the exclude list.
boolean isExcluded = false; boolean isExcluded = false;
if (zone.size() > 1) { for (int i = 0; i < zone.size(); i++) {
ZoneRec zrec = zone.get(zone.size()-2); ZoneRec zrec = zone.get(i);
if ((zrec.getGmtOffset() != rawOffset) if ((zrec.getGmtOffset() != rawOffset)
&& (zrec.getUntilTime(0) > Time.getCurrentTime())) { && (zrec.getUntilTime(0) > Time.getCurrentTime())) {
if (excludeList == null) { if (excludeList == null) {
...@@ -85,6 +85,7 @@ class Mappings { ...@@ -85,6 +85,7 @@ class Mappings {
} }
excludeList.add(zone.getName()); excludeList.add(zone.getName());
isExcluded = true; isExcluded = true;
break;
} }
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册