]> granicus.if.org Git - icu/commitdiff
ICU-10256 Fixed NPE problem in TimeZoneJDK#clone().
authorYoshito Umaoka <y.umaoka@gmail.com>
Tue, 13 Aug 2013 14:35:01 +0000 (14:35 +0000)
committerYoshito Umaoka <y.umaoka@gmail.com>
Tue, 13 Aug 2013 14:35:01 +0000 (14:35 +0000)
X-SVN-Rev: 34038

icu4j/main/classes/localespi/src/com/ibm/icu/impl/icuadapter/TimeZoneJDK.java

index 8e0221f8f96b52ae3fb390f725807482aa5859c3..7bba63772bfc24baf52184b70bc2db7704f6955f 100644 (file)
@@ -1,6 +1,6 @@
 /*
  *******************************************************************************
- * Copyright (C) 2008-2012, International Business Machines Corporation and    *
+ * Copyright (C) 2008-2013, International Business Machines Corporation and    *
  * others. All Rights Reserved.                                                *
  *******************************************************************************
  */
@@ -224,7 +224,7 @@ public class TimeZoneJDK extends com.ibm.icu.util.TimeZone {
     public com.ibm.icu.util.TimeZone cloneAsThawed() {
         TimeZoneJDK tz = (TimeZoneJDK)super.cloneAsThawed();
         tz.fJdkTz = (TimeZone)fJdkTz.clone();
-        tz.fJdkCal = (java.util.GregorianCalendar)fJdkCal.clone();
+        tz.fJdkCal = null;  // To be instantiated when necessary
         tz.fIsFrozen = false;
         return tz;
     }