You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@cocoon.apache.org by ha...@apache.org on 2001/07/10 13:18:22 UTC

cvs commit: xml-cocoon2/src/org/apache/cocoon/acting AbstractValidatorAction.java

haul        01/07/10 04:18:22

  Modified:    src/org/apache/cocoon/acting AbstractValidatorAction.java
  Log:
  Fix bug 2414. Test for empty string in validateLong replaced by test
  for null
  
  Revision  Changes    Path
  1.6       +5 -5      xml-cocoon2/src/org/apache/cocoon/acting/AbstractValidatorAction.java
  
  Index: AbstractValidatorAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/AbstractValidatorAction.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- AbstractValidatorAction.java	2001/06/15 11:49:19	1.5
  +++ AbstractValidatorAction.java	2001/07/10 11:18:18	1.6
  @@ -1,4 +1,4 @@
  -// $Id: AbstractValidatorAction.java,v 1.5 2001/06/15 11:49:19 dims Exp $
  +// $Id: AbstractValidatorAction.java,v 1.6 2001/07/10 11:18:18 haul Exp $
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.configuration.Configurable;
  @@ -102,7 +102,8 @@
    * </tr>
    * </table>
    * @author Martin Man &lt;Martin.Man@seznam.cz&gt;
  - * @version CVS $Revision: 1.5 $ $Date: 2001/06/15 11:49:19 $
  + * @author <a href="mailto:haul@informatik.tu-darmstadt.de">Christian Haul</a>
  + * @version CVS $Revision: 1.6 $ $Date: 2001/07/10 11:18:18 $
    */
   public abstract class AbstractValidatorAction
   extends AbstractComplementaryConfigurableAction
  @@ -189,7 +190,6 @@
               getLogger().debug ("VALIDATOR: string parameter "
                       + name + " is null");
   	    if ( !nullable ){
  -		ValidatorActionHelper vah = new ValidatorActionHelper ( value, ValidatorActionResult.ISNULL );
   		    return new ValidatorActionHelper ( value, ValidatorActionResult.ISNULL );}
   	    else 
   		value = dflt;
  @@ -352,7 +352,7 @@
   	    }
   
   	    // Validate wheter param is at most max
  -	    if (!"".equals (max)) {
  +	    if (max != null) {
   		getLogger().debug ("VALIDATOR: long parameter "
   				   + name + " should be at most " + max);
   		if (max.compareTo(value)<0) {
  @@ -624,5 +624,5 @@
   
   }
   
  -// $Id: AbstractValidatorAction.java,v 1.5 2001/06/15 11:49:19 dims Exp $
  +// $Id: AbstractValidatorAction.java,v 1.6 2001/07/10 11:18:18 haul Exp $
   // vim: set et ts=4 sw=4:
  
  
  

----------------------------------------------------------------------
In case of troubles, e-mail:     webmaster@xml.apache.org
To unsubscribe, e-mail:          cocoon-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-cvs-help@xml.apache.org