summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Koch <konqueror@gmx.de>2005-01-06 11:38:48 +0000
committerMichael Koch <konqueror@gmx.de>2005-01-06 11:38:48 +0000
commit39703a09c2cdd8194897b775fa917bae8f39b49b (patch)
tree9526b6faefd3ec17837b9eb7e34bf64a29e55d80
parent49660c06d78c7851acc55fe065d47215dfc99633 (diff)
downloadclasspath-39703a09c2cdd8194897b775fa917bae8f39b49b.tar.gz
2005-01-06 Michael Koch <konqueror@gmx.de>
* java/util/TimeZone.java (setID): Throw NullPointerException if needed.
-rw-r--r--ChangeLog5
-rw-r--r--java/util/TimeZone.java4
2 files changed, 9 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 0d50dd84a..16a0eadbc 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2005-01-06 Michael Koch <konqueror@gmx.de>
+
+ * java/util/TimeZone.java
+ (setID): Throw NullPointerException if needed.
+
2005-01-05 Mark Wielaard <mark@klomp.org>
* lib/gen-classlist.sh.in: Don't split locales in classes.locale1
diff --git a/java/util/TimeZone.java b/java/util/TimeZone.java
index 39cdcd3e2..0685e6046 100644
--- a/java/util/TimeZone.java
+++ b/java/util/TimeZone.java
@@ -989,9 +989,13 @@ public abstract class TimeZone implements java.io.Serializable, Cloneable
* Sets the identifier of this time zone. For instance, PST for
* Pacific Standard Time.
* @param id the new time zone ID.
+ * @throws NullPointerException if <code>id</code> is <code>null</code>
*/
public void setID(String id)
{
+ if (id == null)
+ throw new NullPointerException();
+
this.ID = id;
}