poi-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kl...@apache.org
Subject cvs commit: jakarta-poi/src/testcases/org/apache/poi/hpsf/data TestSolidWorks.sldprt
Date Thu, 08 Jan 2004 14:25:35 GMT
klute       2004/01/08 06:25:35

  Modified:    src/java/org/apache/poi/hpsf Property.java
  Added:       src/testcases/org/apache/poi/hpsf/data TestSolidWorks.sldprt
  Log:
  Buf fix plus testcasde: Reading property values failed with a StringIndexOutOfBoundsException
on empty strings.
  
  Revision  Changes    Path
  1.17      +2 -2      jakarta-poi/src/java/org/apache/poi/hpsf/Property.java
  
  Index: Property.java
  ===================================================================
  RCS file: /home/cvs/jakarta-poi/src/java/org/apache/poi/hpsf/Property.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -r1.16 -r1.17
  --- Property.java	2 Dec 2003 17:46:01 -0000	1.16
  +++ Property.java	8 Jan 2004 14:25:35 -0000	1.17
  @@ -265,7 +265,7 @@
                       b.append((char) src[o + j]);
   
               /* Strip 0x00 characters from the end of the string: */
  -            while (b.charAt(b.length() - 1) == 0x00)
  +            while (b.length() > 0 && b.charAt(b.length() - 1) == 0x00)
                   b.setLength(b.length() - 1);
               if (codepage == CP_UNICODE)
               {
  
  
  
  1.1                  jakarta-poi/src/testcases/org/apache/poi/hpsf/data/TestSolidWorks.sldprt
  
  	<<Binary file>>
  
  

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


Mime
View raw message