commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jstrac...@apache.org
Subject cvs commit: jakarta-commons-sandbox/jelly/src/java/org/apache/commons/jelly/tags/sql QueryTag.java
Date Mon, 20 May 2002 12:43:15 GMT
jstrachan    02/05/20 05:43:15

  Modified:    jelly    build.xml
               jelly/src/java/org/apache/commons/jelly/tags/sql
                        QueryTag.java
  Log:
  Patched bug in <sql:query> tag which wasn't correctly clearing out previous parameters
if the tag gets reused
  
  Revision  Changes    Path
  1.19      +2 -2      jakarta-commons-sandbox/jelly/build.xml
  
  Index: build.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-commons-sandbox/jelly/build.xml,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- build.xml	17 May 2002 15:18:14 -0000	1.18
  +++ build.xml	20 May 2002 12:43:15 -0000	1.19
  @@ -2,7 +2,7 @@
   
   <!--
           "Jelly" component of the Jakarta Commons Subproject
  -        $Id: build.xml,v 1.18 2002/05/17 15:18:14 jstrachan Exp $
  +        $Id: build.xml,v 1.19 2002/05/20 12:43:15 jstrachan Exp $
   -->
   
   <!-- ========== Initialize Properties ===================================== -->
  @@ -329,7 +329,7 @@
       <mkdir      dir="${dist.home}/docs/api"/>
       <javadoc sourcepath="${source.home}"
                   destdir="${dist.home}/docs/api"
  -           packagenames="org.apache.commons.*"
  +           packagenames="org.*, javax.*"
                    author="true"
                   private="true"
                   version="true"
  
  
  
  1.5       +2 -1      jakarta-commons-sandbox/jelly/src/java/org/apache/commons/jelly/tags/sql/QueryTag.java
  
  Index: QueryTag.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons-sandbox/jelly/src/java/org/apache/commons/jelly/tags/sql/QueryTag.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- QueryTag.java	17 May 2002 15:18:09 -0000	1.4
  +++ QueryTag.java	20 May 2002 12:43:15 -0000	1.5
  @@ -253,6 +253,7 @@
               setParameters(ps, parameters);
               ResultSet rs = ps.executeQuery();
               result = new ResultImpl(rs, startRow, maxRows);
  +            context.setVariable(var, result);
           }
           catch (SQLException e) {
               throw new JellyException(sqlStatement + ": " + e.getMessage(), e);
  @@ -266,8 +267,8 @@
                   } // Not much we can do
                   conn = null;
               }
  +            parameters = null;
           }
  -        context.setVariable(var, result);
       }
   
       //*********************************************************************
  
  
  

--
To unsubscribe, e-mail:   <mailto:commons-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:commons-dev-help@jakarta.apache.org>


Mime
View raw message