Author: sebb
Date: Thu Oct  6 15:13:44 2011
New Revision: 1179657

URL: http://svn.apache.org/viewvc?rev=1179657&view=rev
Log:
Bug 51980 - HtmlParserHTMLParser double-counts images used in links

Modified:
    jakarta/jmeter/trunk/bin/testfiles/HTMLParserTestCase.html
    
jakarta/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/parser/HtmlParserHTMLParser.java
    jakarta/jmeter/trunk/xdocs/changes.xml

Modified: jakarta/jmeter/trunk/bin/testfiles/HTMLParserTestCase.html
URL: 
http://svn.apache.org/viewvc/jakarta/jmeter/trunk/bin/testfiles/HTMLParserTestCase.html?rev=1179657&r1=1179656&r2=1179657&view=diff
==============================================================================
--- jakarta/jmeter/trunk/bin/testfiles/HTMLParserTestCase.html (original)
+++ jakarta/jmeter/trunk/bin/testfiles/HTMLParserTestCase.html Thu Oct  6 
15:13:44 2011
@@ -8,7 +8,7 @@
 </tr>
 </table>
 <img src="images/image-b.gif" name="b" align="top"/>
-<img src="images/image-b.gif" name="b" align="top"/>
+<a href="somewhere"><img src="images/image-b.gif" name="b" align="top"/></a>
 <img align="top" name="c" src= "images/image-c.gif">
 <img name="d" align="top" src ="images/image-d.gif"/>
 <img

Modified: 
jakarta/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/parser/HtmlParserHTMLParser.java
URL: 
http://svn.apache.org/viewvc/jakarta/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/parser/HtmlParserHTMLParser.java?rev=1179657&r1=1179656&r2=1179657&view=diff
==============================================================================
--- 
jakarta/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/parser/HtmlParserHTMLParser.java
 (original)
+++ 
jakarta/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/parser/HtmlParserHTMLParser.java
 Thu Oct  6 15:13:44 2011
@@ -35,7 +35,6 @@ import org.htmlparser.tags.CompositeTag;
 import org.htmlparser.tags.FrameTag;
 import org.htmlparser.tags.ImageTag;
 import org.htmlparser.tags.InputTag;
-import org.htmlparser.tags.LinkTag;
 import org.htmlparser.tags.ScriptTag;
 import org.htmlparser.util.NodeIterator;
 import org.htmlparser.util.ParserException;
@@ -153,12 +152,6 @@ class HtmlParserHTMLParser extends HTMLP
                     // then we need to download the binary
                     binUrlStr = tag.getAttribute(ATT_SRC);
                 }
-            } else if (tag instanceof LinkTag) {
-                LinkTag link = (LinkTag) tag;
-                if (link.getChild(0) instanceof ImageTag) {
-                    ImageTag img = (ImageTag) link.getChild(0);
-                    binUrlStr = img.getImageURL();
-                }
             } else if (tag instanceof ScriptTag) {
                 binUrlStr = tag.getAttribute(ATT_SRC);
                 // Bug 51750

Modified: jakarta/jmeter/trunk/xdocs/changes.xml
URL: 
http://svn.apache.org/viewvc/jakarta/jmeter/trunk/xdocs/changes.xml?rev=1179657&r1=1179656&r2=1179657&view=diff
==============================================================================
--- jakarta/jmeter/trunk/xdocs/changes.xml (original)
+++ jakarta/jmeter/trunk/xdocs/changes.xml Thu Oct  6 15:13:44 2011
@@ -86,6 +86,7 @@ This has been corrected; can still rever
 <li>Bug 51942 - Synchronisation issue on CacheManager when Concurrent Download 
is used</li>
 <li>Bug 51957 - Concurrent get can hang if a task does not complete</li>
 <li>Bug 51925 - Calling Stop on Test leaks executor threads when concurrent 
download of resources is on</li>
+<li>Bug 51980 - HtmlParserHTMLParser double-counts images used in links</li>
 </ul>
 
 <h3>Other Samplers</h3>



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to