Author: remy.maucherat(a)jboss.com
Date: 2007-09-24 06:29:20 -0400 (Mon, 24 Sep 2007)
New Revision: 282
Modified:
trunk/java/org/apache/catalina/Context.java
trunk/java/org/apache/catalina/core/StandardContext.java
trunk/java/org/apache/el/lang/FunctionMapperImpl.java
Log:
- Remove unused findStatusPages.
- Fix CNFE and NPE in function mapper (bug 41797).
Modified: trunk/java/org/apache/catalina/Context.java
===================================================================
--- trunk/java/org/apache/catalina/Context.java 2007-09-24 08:15:46 UTC (rev 281)
+++ trunk/java/org/apache/catalina/Context.java 2007-09-24 10:29:20 UTC (rev 282)
@@ -764,15 +764,6 @@
/**
- * Return the context-relative URI of the error page for the specified
- * HTTP status code, if any; otherwise return <code>null</code>.
- *
- * @param status HTTP status code to look up
- */
- public String findStatusPage(int status);
-
-
- /**
* Return the set of HTTP status codes for which error pages have
* been specified. If none are specified, a zero-length array
* is returned.
Modified: trunk/java/org/apache/catalina/core/StandardContext.java
===================================================================
--- trunk/java/org/apache/catalina/core/StandardContext.java 2007-09-24 08:15:46 UTC (rev
281)
+++ trunk/java/org/apache/catalina/core/StandardContext.java 2007-09-24 10:29:20 UTC (rev
282)
@@ -2963,19 +2963,6 @@
/**
- * Return the context-relative URI of the error page for the specified
- * HTTP status code, if any; otherwise return <code>null</code>.
- *
- * @param status HTTP status code to look up
- */
- public String findStatusPage(int status) {
-
- return ((String) statusPages.get(new Integer(status)));
-
- }
-
-
- /**
* Return the set of HTTP status codes for which error pages have
* been specified. If none are specified, a zero-length array
* is returned.
Modified: trunk/java/org/apache/el/lang/FunctionMapperImpl.java
===================================================================
--- trunk/java/org/apache/el/lang/FunctionMapperImpl.java 2007-09-24 08:15:46 UTC (rev
281)
+++ trunk/java/org/apache/el/lang/FunctionMapperImpl.java 2007-09-24 10:29:20 UTC (rev
282)
@@ -32,7 +32,7 @@
/**
* @author Jacob Hookom [jacob(a)hookom.net]
- * @version $Change: 181177 $$DateTime: 2001/06/26 08:45:09 $$Author: markt $
+ * @version $Change: 181177 $$DateTime: 2001/06/26 08:45:09 $$Author: funkman $
*/
public class FunctionMapperImpl extends FunctionMapper implements
Externalizable {
@@ -120,9 +120,16 @@
public void writeExternal(ObjectOutput out) throws IOException {
out.writeUTF((this.prefix != null) ? this.prefix : "");
out.writeUTF(this.localName);
- out.writeUTF(this.m.getDeclaringClass().getName());
- out.writeUTF(this.m.getName());
- out.writeObject(ReflectionUtil.toTypeNameArray(this.m.getParameterTypes()));
+ out.writeUTF((this.owner != null) ?
+ this.owner :
+ this.m.getDeclaringClass().getName());
+ out.writeUTF((this.name != null) ?
+ this.name :
+ this.m.getName());
+ out.writeObject((this.types != null) ?
+ this.types :
+ ReflectionUtil.toTypeNameArray(this.m.getParameterTypes()));
+
}
/*
@@ -144,7 +151,7 @@
public Method getMethod() {
if (this.m == null) {
try {
- Class t = Class.forName(this.owner);
+ Class t = ReflectionUtil.forName(this.owner);
Class[] p = ReflectionUtil.toTypeArray(this.types);
this.m = t.getMethod(this.name, p);
} catch (Exception e) {
Show replies by date