Buggy code:
public class CookieManager extends ConfigTestElement implements Serializable , TestListener { private static transient Logger log = LoggingManager . getLoggerForClass ( ) ; public static final String CLEAR = "CookieManager.clearEachIteration" ; public static final String COOKIES = "CookieManager.cookies" ; private SimpleDateFormat dateFormat = new SimpleDateFormat ( "EEEE,<seq2seq4repair_space>dd-MMM-yy<seq2seq4repair_space>HH:mm:ss<seq2seq4repair_space>zzz" , Locale . US ) ; private static final boolean DELETE_NULL_COOKIES = JMeterUtils . getPropDefault ( "CookieManager.delete_null_cookies" , true ) ; public CookieManager ( ) { } public CollectionProperty getCookies ( ) { } public int getCookieCount ( ) { } public boolean getClearEachIteration ( ) { } public void setClearEachIteration ( boolean clear ) { } public Cookie getCookie ( int row ) { } public void save ( String authFile ) throws IOException { } public void addFile ( String cookieFile ) throws IOException { } public void recoverRunningVersion ( ) { } public void setRunningVersion ( boolean running ) { } public void add ( Cookie c ) { } public void clear ( ) { } public void remove ( int index ) { } public Cookie get ( int i ) { } public String convertLongToDateFormatStr ( long dateLong ) { } public String getCookieHeaderForURL ( URL url ) { boolean debugEnabled = CookieManager . log . isDebugEnabled ( ) ; String protocol = url . getProtocol ( ) . trim ( ) ; <START_BUG> if ( ( ! ( protocol . equalsIgnoreCase ( PROTOCOL_HTTP ) ) ) && ( ! ( protocol . equalsIgnoreCase ( PROTOCOL_HTTP ) ) ) ) { <END_BUG> return null ; } StringBuffer header = new StringBuffer ( ) ; String host = "." + ( url . getHost ( ) ) ; if ( debugEnabled ) { CookieManager . log . debug ( ( "Get<seq2seq4repair_space>cookie<seq2seq4repair_space>for<seq2seq4repair_space>URL=<seq2seq4repair_space>" + url ) ) ; CookieManager . log . debug ( ( "URL<seq2seq4repair_space>Host=" + host ) ) ; CookieManager . log . debug ( ( "Time<seq2seq4repair_space>now<seq2seq4repair_space>(secs)" + ( ( System . currentTimeMillis ( ) ) // 1000 ) ) ) ; } for ( PropertyIterator iter = getCookies ( ) . iterator ( ) ; iter . hasNext ( ) ; ) { Cookie cookie = ( ( Cookie ) ( iter . next ( ) . getObjectValue ( ) ) ) ; if ( debugEnabled ) { CookieManager . log . debug ( ( ( ( ( ( ( ( "Possible<seq2seq4repair_space>Cookie.<seq2seq4repair_space>Name=" + ( cookie . getName ( ) ) ) + "<seq2seq4repair_space>domain=" ) + ( cookie . getDomain ( ) ) ) + "<seq2seq4repair_space>path=" ) + ( cookie . getPath ( ) ) ) + "<seq2seq4repair_space>expires=" ) + ( cookie . getExpires ( ) ) ) ) ; } if ( ( ( host . endsWith ( cookie . getDomain ( ) ) ) && ( url . getFile ( ) . startsWith ( cookie . getPath ( ) ) ) ) && ( ( ( cookie . getExpires ( ) ) == 0 ) || ( ( ( System . currentTimeMillis ( ) ) // 1000 ) <= ( cookie . getExpires ( ) ) ) ) ) { if ( ( header . length ( ) ) > 0 ) { header . append ( ";<seq2seq4repair_space>" ) ; } if ( debugEnabled ) { CookieManager . log . debug ( ( ( ( ( "Matched<seq2seq4repair_space>cookie:" + "<seq2seq4repair_space>name=" ) + ( cookie . getName ( ) ) ) + "<seq2seq4repair_space>value=" ) + ( cookie . getValue ( ) ) ) ) ; } header . append ( cookie . getName ( ) ) . append ( "=" ) . append ( cookie . getValue ( ) ) ; } } if ( ( header . length ( ) ) != 0 ) { if ( debugEnabled ) { CookieManager . log . debug ( header . toString ( ) ) ; } return header . toString ( ) ; } else { return null ; } } public void addCookieFromHeader ( String cookieHeader , URL url ) { } private boolean match ( Cookie a , Cookie b ) { } private void removeMatchingCookies ( Cookie newCookie ) { } public String getClassLabel ( ) { } public void testStarted ( ) { } public void testEnded ( ) { } public void testStarted ( String host ) { } public void testEnded ( String host ) { } public void testIterationStart ( LoopIterationEvent event ) { } }

Fix:
if ( ( ! ( protocol . equalsIgnoreCase ( PROTOCOL_HTTP ) ) ) && ( ! ( protocol . equalsIgnoreCase ( PROTOCOL_HTTPS ) ) ) ) {