webwork/src/main/webwork/util BeanUtil.java,1.17,1.18

[email protected] Thu, 16 May 2002 20:32:23 -0700
Newsgroups gmane.comp.java.webwork.cvs
Message-ID <[email protected]>
Update of /cvsroot/webwork/webwork/src/main/webwork/util
In directory usw-pr-cvs1:/tmp/cvs-serv1310

Modified Files:
	BeanUtil.java 
Log Message:
check for npe

Index: BeanUtil.java
===================================================================
RCS file: /cvsroot/webwork/webwork/src/main/webwork/util/BeanUtil.java,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -d -r1.17 -r1.18
--- BeanUtil.java	24 Apr 2002 20:22:08 -0000	1.17
+++ BeanUtil.java	17 May 2002 03:32:21 -0000	1.18
@@ -359,6 +359,9 @@
          log.warn("No descriptor found for. Unable to set value. ");
          return false;
       }
+      //no value, so don't set it.
+      if (val==null) return false;
+
       Method m = descriptor.getWriteMethod();
       Class valueClass = val.getClass();
       Class parameterClass = m.getParameterTypes()[0];



_______________________________________________________________

Have big pipes? SourceForge.net is looking for download mirrors. We supply
the hardware. You get the recognition. Email Us: [email protected]