Buggy code:
public class HtmlParser implements Serializable { private static Logger log = Hierarchy . getDefaultHierarchy ( ) . getLoggerFor ( "jmeter.protocol.http" ) ; protected static String utfEncodingName ; private int compilerOptions = ( ( Perl5Compiler . CASE_INSENSITIVE_MASK ) | ( Perl5Compiler . MULTILINE_MASK ) ) | ( Perl5Compiler . READ_ONLY_MASK ) ; private static transient Perl5Compiler compiler = new Perl5Compiler ( ) ; private static transient Perl5Matcher matcher = new Perl5Matcher ( ) ; public HtmlParser ( ) { } public static synchronized boolean isAnchorMatched ( HTTPSampler newLink , HTTPSampler config ) throws MalformedPatternException { } public static synchronized boolean isArgumentMatched ( Argument arg , Argument patternArg ) throws MalformedPatternException { } public static Tidy getParser ( ) { } public static Node getDOM ( String text ) throws SAXException { } public static String getUTFEncodingName ( ) { } public static Document createEmptyDoc ( ) { } public static HTTPSampler createUrlFromAnchor ( String parsedUrlString , HTTPSampler context ) throws MalformedURLException { } public static List createURLFromForm ( Node doc , HTTPSampler context ) { } private static boolean recurseForm ( Node tempNode , LinkedList urlConfigs , HTTPSampler context , String selectName , boolean inForm ) { NamedNodeMap nodeAtts = tempNode . getAttributes ( ) ; String tag = tempNode . getNodeName ( ) ; try { if ( inForm ) { HTTPSampler url = ( ( HTTPSampler ) ( urlConfigs . getLast ( ) ) ) ; if ( tag . equalsIgnoreCase ( "form" ) ) { try { urlConfigs . add ( HtmlParser . createFormUrlConfig ( tempNode , context ) ) ; } catch ( MalformedURLException e ) { inForm = false ; } } else if ( tag . equalsIgnoreCase ( "input" ) ) { url . addArgument ( HtmlParser . getAttributeValue ( nodeAtts , "name" ) , HtmlParser . getAttributeValue ( nodeAtts , "value" ) ) ; } else if ( tag . equalsIgnoreCase ( "textarea" ) ) try { url . addArgument ( HtmlParser . getAttributeValue ( nodeAtts , "name" ) , tempNode . getFirstChild ( ) . getNodeValue ( ) ) ; } catch ( NullPointerException e ) { url . addArgument ( HtmlParser . getAttributeValue ( nodeAtts , "name" ) , "" ) ; } else if ( tag . equalsIgnoreCase ( "select" ) ) selectName = HtmlParser . getAttributeValue ( nodeAtts , "name" ) ; else if ( tag . equalsIgnoreCase ( "option" ) ) { String value = HtmlParser . getAttributeValue ( nodeAtts , "value" ) ; if ( value == null ) { try { value = tempNode . getFirstChild ( ) . getNodeValue ( ) ; } catch ( NullPointerException e ) { value = "" ; } } url . addArgument ( selectName , value ) ; } } else if ( tag . equalsIgnoreCase ( "form" ) ) { try { urlConfigs . add ( HtmlParser . createFormUrlConfig ( tempNode , context ) ) ; inForm = true ; } catch ( MalformedURLException e ) { inForm = false ; } try { Thread . sleep ( 5000 ) ; } catch ( Exception e ) { } } } catch ( Exception ex ) { <START_BUG> System . out . println ( ( "Some<seq2seq4repair_space>bad<seq2seq4repair_space>HTML<seq2seq4repair_space>" + ( HtmlParser . printNode ( tempNode ) ) ) ) ; <END_BUG> } NodeList childNodes = tempNode . getChildNodes ( ) ; for ( int x = 0 ; x < ( childNodes . getLength ( ) ) ; x ++ ) { inForm = HtmlParser . recurseForm ( childNodes . item ( x ) , urlConfigs , context , selectName , inForm ) ; } return inForm ; } private static String getAttributeValue ( NamedNodeMap att , String attName ) { } private static String printNode ( Node node ) { } public static class Test extends TestCase { private static Logger log = Hierarchy . getDefaultHierarchy ( ) . getLoggerFor ( "jmeter.test" ) ; public Test ( String name ) { } public void testGetUTFEncodingName ( ) { } protected void setUp ( ) { } } private static HTTPSampler createFormUrlConfig ( Node tempNode , HTTPSampler context ) throws MalformedURLException { } }

Fix:
HtmlParser . log . warn ( ( "Some<seq2seq4repair_space>bad<seq2seq4repair_space>HTML<seq2seq4repair_space>" + ( HtmlParser . printNode ( tempNode ) ) ) , ex ) ;