jakarta-taglibs-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hor...@apache.org
Subject cvs commit: jakarta-taglibs/standard/src/org/apache/taglibs/standard/tag/common/sql DataSourceUtil.java
Date Fri, 18 Jun 2004 17:36:00 GMT
horwat      2004/06/18 10:36:00

  Modified:    standard/src/org/apache/taglibs/standard/tag/common/sql Tag:
                        STANDARD_1_0_BRANCH DataSourceUtil.java
  Log:
  Port of JSTL 1.1.x fix.
  
  <sql:dataSource> accepts the value for the dataSource attribute in the following format:
  
    dataSource="<db-url>,<driver-classname>,<db-user>,<db-password>"
  
  If there is a space after the ",", then JSTL considers it as a part of the parameter. Ideally
all the tokens should be trimmed.
  
  Revision  Changes    Path
  No                   revision
  No                   revision
  1.10.2.3  +2 -2      jakarta-taglibs/standard/src/org/apache/taglibs/standard/tag/common/sql/DataSourceUtil.java
  
  Index: DataSourceUtil.java
  ===================================================================
  RCS file: /home/cvs/jakarta-taglibs/standard/src/org/apache/taglibs/standard/tag/common/sql/DataSourceUtil.java,v
  retrieving revision 1.10.2.2
  retrieving revision 1.10.2.3
  diff -u -r1.10.2.2 -r1.10.2.3
  --- DataSourceUtil.java	28 Feb 2004 06:08:11 -0000	1.10.2.2
  +++ DataSourceUtil.java	18 Jun 2004 17:36:00 -0000	1.10.2.3
  @@ -101,7 +101,7 @@
               char nextChar = params.charAt(index);
               if (TOKEN.indexOf(nextChar) != -1) {
                   if (escCount == 0) {
  -                    paramString[aryCount] = params.substring(begin,index);
  +                    paramString[aryCount] = params.substring(begin,index).trim();
                       begin = index + 1;
                       if (++aryCount > 4) {
                           throw new JspTagException(
  @@ -116,7 +116,7 @@
                   escCount = 0;
               }
           }
  -        paramString[aryCount] = params.substring(begin);
  +        paramString[aryCount] = params.substring(begin).trim();
   
   	// use the JDBC URL from the parameter string
           dataSource.setJdbcURL(paramString[0]);
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: taglibs-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: taglibs-dev-help@jakarta.apache.org


Mime
View raw message