xml-rpc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d..@apache.org
Subject cvs commit: xml-rpc/src/java/org/apache/xmlrpc XmlRpcServer.java
Date Wed, 07 Aug 2002 02:41:25 GMT
dlr         2002/08/06 19:41:25

  Modified:    src/java/org/apache/xmlrpc XmlRpcServer.java
  Log:
  Invoker.execute(): Added check for unsupported void return type on
  handler methods.  The need for better error reporting for this snafu
  was pointed out on the user list by Dejan Bosanace
  <dejan_b@datagate.co.uk>.
  
  Revision  Changes    Path
  1.25      +7 -1      xml-rpc/src/java/org/apache/xmlrpc/XmlRpcServer.java
  
  Index: XmlRpcServer.java
  ===================================================================
  RCS file: /home/cvs/xml-rpc/src/java/org/apache/xmlrpc/XmlRpcServer.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -u -r1.24 -r1.25
  --- XmlRpcServer.java	20 Mar 2002 15:11:03 -0000	1.24
  +++ XmlRpcServer.java	7 Aug 2002 02:41:25 -0000	1.25
  @@ -547,6 +547,12 @@
               // It is some other exception
               throw new Exception(t.toString());
           }
  +        if (returnValue == null && method.getReturnType() == Void.TYPE)
  +        {
  +            // Not supported by the spec.
  +            throw new IllegalArgumentException
  +                ("void return types for handler methods not supported");
  +        }
           return returnValue;
       }
   }
  
  
  

Mime
View raw message