summaryrefslogtreecommitdiff
path: root/java/security
diff options
context:
space:
mode:
authorMark Wielaard <mark@klomp.org>2006-03-17 10:55:27 +0000
committerMark Wielaard <mark@klomp.org>2006-03-17 10:55:27 +0000
commit6c99d6627576eafb4301a1f3822afa2840c67369 (patch)
treedec4412481714aa22b975e9d820aa4518c608b27 /java/security
parentf09dee0c326e6d7cd81872d0bc25f45f3ae2e19d (diff)
downloadclasspath-6c99d6627576eafb4301a1f3822afa2840c67369.tar.gz
* java/security/BasicPermission.java (BasicPermission): Check
name equals empty string to force NullPointerException.
Diffstat (limited to 'java/security')
-rw-r--r--java/security/BasicPermission.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/java/security/BasicPermission.java b/java/security/BasicPermission.java
index 267a6e292..ef2cc4df0 100644
--- a/java/security/BasicPermission.java
+++ b/java/security/BasicPermission.java
@@ -1,5 +1,6 @@
/* BasicPermission.java -- implements a simple named permission
- Copyright (C) 1998, 1999, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
+ Copyright (C) 1998, 1999, 2002, 2003, 2004, 2005, 2006
+ Free Software Foundation, Inc.
This file is part of GNU Classpath.
@@ -97,7 +98,7 @@ public abstract class BasicPermission extends java.security.Permission
// requirement exists in the specification and Sun's runtime
// doesn't appear to do it.
- if ("".equals(name))
+ if (name.equals(""))
throw new IllegalArgumentException("Empty name");
}