nus-yam/ex-repair huggingface dataset:
Buggy code:
public class RunSlimfinder { CyNetwork network ; private SlimfinderOptionsPanel optionsPanel ; String url ; public RunSlimfinder ( CyNetwork network , List < CyNode > selected , List < String > uniprotIDs , SlimfinderOptionsPanel optionsPanel ) { } private List < String > getNodeIds ( List < CyNode > selected ) { } public String constructUrl ( SlimfinderOptionsPanel optionsPanel , List < String > uniprotIDs ) { SlimfinderOptions options = optionsPanel . getSLiMFinderOptions ( ) ; boolean dismask = options . getDismask ( ) ; boolean conservation = options . getConsmask ( ) ; boolean featuremask = options . getFeaturemask ( ) ; String walltime = options . getWalltime ( ) ; double cutoff = options . getCutoff ( ) ; String custom = options . getCustomParameters ( ) ; StringBuilder stringBuilder = new StringBuilder ( "http:////rest.slimsuite.unsw.edu.au//slimfinder" ) ; String dismaskS = "&dismask=" ; if ( dismask ) { stringBuilder . append ( ( dismaskS + "T" ) ) ; } else { stringBuilder . append ( ( dismaskS + "F" ) ) ; } String consmaskS = "&consmask=" ; if ( conservation ) { stringBuilder . append ( ( consmaskS + "T" ) ) ; } else { stringBuilder . append ( ( consmaskS + "F" ) ) ; } <START_BUG> String featuremaskS = "&consmask=" ; <END_BUG> if ( featuremask ) { stringBuilder . append ( ( featuremaskS + "T" ) ) ; } else { stringBuilder . append ( ( featuremaskS + "F" ) ) ; } stringBuilder . append ( ( "&probcut=" + cutoff ) ) ; stringBuilder . append ( ( "&walltime=" + walltime ) ) ; custom = custom . replace ( "\n" , "&" ) ; custom = custom . replace ( "<seq2seq4repair_space>" , "" ) ; if ( ( custom . length ( ) ) > 0 ) { stringBuilder . append ( ( "&" + custom ) ) ; } String ids = "&uniprotid=" ; for ( String id : uniprotIDs ) { ids = ( ids + id ) + "," ; } ids = ids . substring ( 0 , ( ( ids . length ( ) ) - 1 ) ) ; stringBuilder . append ( ids ) ; return stringBuilder . toString ( ) ; } public String getUrl ( ) { } }

Fix:
String featuremaskS = "&featuremask=" ;
Buggy code:
public class Tools { static final String CORE = "core" ; static final String STANDALONE = "standalone" ; static final String VERSION = "version" ; static ModelNode getAndCheckResult ( ModelNode result ) { if ( ! ( result . get ( OUTCOME ) . asString ( ) . equals ( SUCCESS ) ) ) { <START_BUG> throw new RuntimeException ( result . get ( FAILURE_DESCRIPTION ) . asString ( ) ) ; <END_BUG> } return result . get ( RESULT ) ; } static ModelVersion createModelVersion ( ModelNode node ) { } static ModelNode readModelVersionFields ( ModelNode node ) { } static ModelNode getCurrentModelVersions ( ) throws Exception { } static ModelNode getCurrentRunningResourceDefinition ( PathAddress pathAddress ) throws Exception { } static ModelNode getCurrentRunningDomainResourceDefinition ( ) throws Exception { } static int readVersion ( ModelNode node , String name ) { } static void serializeModeNodeToFile ( ModelNode modelNode , File file ) throws Exception { } static ModelNode loadModelNodeFromFile ( File file ) throws Exception { } }

Fix:
throw new RuntimeException ( result . get ( FAILURE_DESCRIPTION ) . toString ( ) ) ;
Buggy code:
public class GenericSubsystemDescribeHandler implements OperationStepHandler , DescriptionProvider { public static final GenericSubsystemDescribeHandler INSTANCE = new GenericSubsystemDescribeHandler ( ) ; public static final SimpleOperationDefinition DEFINITION = new org . jboss . as . controller . SimpleOperationDefinitionBuilder ( DESCRIBE , CommonDescriptions . getResourceDescriptionResolver ( SUBSYSTEM ) ) . setReplyType ( LIST ) . setReplyValueType ( OBJECT ) . setPrivateEntry ( ) . build ( ) ; protected GenericSubsystemDescribeHandler ( ) { } @ Override public void execute ( final OperationContext context , final ModelNode operation ) throws OperationFailedException { final ModelNode address ; final PathAddress pa = PathAddress . pathAddress ( PathAddress . pathAddress ( operation . require ( OP_ADDR ) ) ) ; if ( ( pa . size ( ) ) > 0 ) { address = new ModelNode ( ) . add ( pa . getLastElement ( ) . getKey ( ) , pa . getLastElement ( ) . getValue ( ) ) ; } else { address = new ModelNode ( ) . setEmptyList ( ) ; } final Resource resource = context . readResource ( EMPTY_ADDRESS ) ; final ModelNode result = context . getResult ( ) ; describe ( resource , address , result , context . getResourceRegistration ( ) ) ; <START_BUG> context . completeStep ( ) ; <END_BUG> } protected void describe ( final Resource resource , final ModelNode address , ModelNode result , final ImmutableManagementResourceRegistration registration ) { } protected ModelNode createAddOperation ( final ModelNode address , final ModelNode subModel , final Set < PathElement > children ) { } @ Override public ModelNode getModelDescription ( Locale locale ) { } }

Fix:
context . stepCompleted ( ) ;
Buggy code:
public class AssistPackageDeclaration extends PackageDeclaration { private Map infoCache ; public AssistPackageDeclaration ( CompilationUnit parent , String name , Map infoCache ) { } public Object getElementInfo ( IProgressMonitor monitor ) throws JavaModelException { <START_BUG> return infoCache . get ( this ) ; <END_BUG> } public IAnnotation getAnnotation ( String name ) { } }

Fix:
return this . infoCache . get ( this ) ;
Buggy code:
public class MarkupInheritanceTest extends WicketTestCase { private static Log log = LogFactory . getLog ( MarkupInheritanceTest . class ) ; public MarkupInheritanceTest ( String name ) { } public void testRenderHomePage_1 ( ) throws Exception { } public void testRenderHomePage_2 ( ) throws Exception { } public void testRenderHomePage_3 ( ) throws Exception { } public void testRenderHomePage_4 ( ) throws Exception { System . out . println ( ( ( "===<seq2seq4repair_space>" + ( MarkupInheritanceExtension_4 . class . getName ( ) ) ) + "<seq2seq4repair_space>===" ) ) ; <START_BUG> application . getRequiredPageSettings ( ) . setHomePage ( MarkupInheritanceExtension_4 . class ) ; <END_BUG> application . setupRequestAndResponse ( ) ; application . processRequestCycle ( ) ; assertEquals ( MarkupInheritanceExtension_4 . class , application . getLastRenderedPage ( ) . getClass ( ) ) ; String document = application . getServletResponse ( ) . getDocument ( ) ; assertTrue ( DiffUtil . validatePage ( document , this . getClass ( ) , "MarkupInheritanceExpectedResult_4.html" ) ) ; MarkupInheritanceExtension_4 page = ( ( MarkupInheritanceExtension_4 ) ( application . getLastRenderedPage ( ) ) ) ; Link link = ( ( Link ) ( page . get ( "link" ) ) ) ; application . setupRequestAndResponse ( ) ; application . getServletRequest ( ) . setRequestToComponent ( link ) ; application . processRequestCycle ( ) ; assertEquals ( MarkupInheritanceExtension_4 . class , application . getLastRenderedPage ( ) . getClass ( ) ) ; document = application . getServletResponse ( ) . getDocument ( ) ; assertTrue ( DiffUtil . validatePage ( document , this . getClass ( ) , "MarkupInheritanceExpectedResult_4-1.html" ) ) ; } public void testRenderHomePage_5 ( ) throws Exception { } public void testRenderHomePage_6 ( ) throws Exception { } public void testRenderHomePage_7 ( ) throws Exception { } public void testRenderHomePage_8 ( ) throws Exception { } public void testRenderHomePage_9 ( ) throws Exception { } }

Fix:
application . setHomePage ( MarkupInheritanceExtension_4 . class ) ;
Buggy code:
public class IntegerConverter extends AbstractIntegerConverter < Integer > { private static final long serialVersionUID = 1L ; public static final IConverter < Integer > INSTANCE = new IntegerConverter ( ) ; <START_BUG> public Integer convertToObject ( final String value , Locale locale ) { <END_BUG> final Number number = parse ( value , Integer . MIN_VALUE , Integer . MAX_VALUE , locale ) ; if ( number == null ) { return null ; } return number . intValue ( ) ; } @ Override protected Class < Integer > getTargetType ( ) { } }

Fix:
public Integer convertToObject ( final String value , final Locale locale ) {
Buggy code:
public class GBM extends SharedTree < GBMModel , GBMModel . GBMParameters , GBMModel . GBMOutput > { @ Override public ModelCategory [ ] can_build ( ) { } public GBM ( GBMModel . GBMParameters parms ) { } @ Override public GBMV2 schema ( ) { } @ Override public Job < GBMModel > trainModel ( ) { } @ Override public Vec vresponse ( ) { } @ Override public void init ( boolean expensive ) { } private static boolean couldBeBool ( Vec v ) { } private class GBMDriver extends Driver { @ Override protected void buildModel ( ) { } class ComputeProb extends MRTask < GBM . GBMDriver . ComputeProb > { @ Override public void map ( Chunk [ ] chks ) { } } class ComputeRes extends MRTask < GBM . GBMDriver . ComputeRes > { @ Override public void map ( Chunk [ ] chks ) { } } private void buildNextKTrees ( ) { } private class GammaPass extends MRTask < GBM . GBMDriver . GammaPass > { final DTree [ ] _trees ; final int [ ] _leafs ; final boolean _isBernoulli ; double [ ] [ ] _rss ; double [ ] [ ] _gss ; GammaPass ( DTree [ ] trees , int [ ] leafs , boolean isBernoulli ) { } @ Override public void map ( Chunk [ ] chks ) { } @ Override public void reduce ( GBM . GBMDriver . GammaPass gp ) { } } @ Override protected GBMModel makeModel ( Key modelKey , GBMModel . GBMParameters parms , double mse_train , double mse_valid ) { } } @ Override protected DecidedNode makeDecided ( UndecidedNode udn , DHistogram [ ] hs ) { } static class GBMDecidedNode extends DecidedNode { GBMDecidedNode ( UndecidedNode n , DHistogram [ ] hs ) { } @ Override public UndecidedNode makeUndecidedNode ( DHistogram [ ] hs ) { } @ Override public Split bestCol ( UndecidedNode u , DHistogram [ ] hs ) { <START_BUG> DTree . Split best = new DTree . Split ( ( - 1 ) , ( - 1 ) , null , ( ( byte ) ( 0 ) ) , Double . MAX_VALUE , Double . MAX_VALUE , Double . MAX_VALUE , 0L , 0L , 0 , 0 ) ; <END_BUG> if ( hs == null ) return best ; for ( int i = 0 ; i < ( hs . length ) ; i ++ ) { if ( ( ( hs [ i ] ) == null ) || ( ( hs [ i ] . nbins ( ) ) <= 1 ) ) continue ; DTree . Split s = hs [ i ] . scoreMSE ( i , _min_rows ) ; if ( s == null ) continue ; if ( ( best == null ) || ( ( s . se ( ) ) < ( best . se ( ) ) ) ) best = s ; if ( ( s . se ( ) ) <= 0 ) break ; } return best ; } } static class GBMUndecidedNode extends UndecidedNode { GBMUndecidedNode ( DTree tree , int pid , DHistogram [ ] hs ) { } @ Override public int [ ] scoreCols ( DHistogram [ ] hs ) { } } static class GBMLeafNode extends LeafNode { GBMLeafNode ( DTree tree , int pid ) { } GBMLeafNode ( DTree tree , int pid , int nid ) { } @ Override protected AutoBuffer compress ( AutoBuffer ab ) { } @ Override protected int size ( ) { } } @ Override protected float score1 ( Chunk [ ] chks , float [ ] fs , int row ) { } }

Fix:
DTree . Split best = new DTree . Split ( ( - 1 ) , ( - 1 ) , null , ( ( byte ) ( 0 ) ) , Float . MAX_VALUE , Float . MAX_VALUE , Float . MAX_VALUE , 0L , 0L , 0 , 0 ) ;
Buggy code:
public class Exit extends Task { private String message ; public void setMessage ( String value ) { } public void execute ( ) throws BuildException { } public void addText ( String msg ) { <START_BUG> message += ProjectHelper . replaceProperties ( project , msg , project . getProperties ( ) ) ; <END_BUG> } }

Fix:
message += ProjectHelper . replaceProperties ( project , msg ) ;
Buggy code:
public class MainActivity extends ActionBarActivity { @ Override protected void onCreate ( Bundle savedInstanceState ) { } protected void onSaveInstanceState ( Bundle outState ) { } @ Override public boolean onCreateOptionsMenu ( Menu menu ) { } @ Override public boolean onOptionsItemSelected ( MenuItem item ) { } public void setValues ( Double tipPercentage ) { final EditText bill = ( ( EditText ) ( findViewById ( billAmount ) ) ) ; final TextView tipTotal = ( ( TextView ) ( findViewById ( tipCount_result ) ) ) ; final TextView totalPrice = ( ( TextView ) ( findViewById ( totalPrice_result ) ) ) ; <START_BUG> if ( ( ! ( bill . getText ( ) . equals ( "" ) ) ) && ( bill . getText ( ) . toString ( ) . matches ( ".*\\d.*" ) ) ) { <END_BUG> NumberFormat numformat = NumberFormat . getCurrencyInstance ( Locale . US ) ; Double enteredBill = Double . parseDouble ( bill . getText ( ) . toString ( ) ) ; Double tip = enteredBill * tipPercentage ; Double price = enteredBill + ( enteredBill * tipPercentage ) ; tipTotal . setText ( numformat . format ( tip ) ) ; totalPrice . setText ( numformat . format ( price ) ) ; } } }

Fix:
if ( ( ! ( bill . getText ( ) . toString ( ) . equals ( "" ) ) ) && ( bill . getText ( ) . toString ( ) . matches ( ".*\\d.*" ) ) ) {
Buggy code:
public class Well1024aTest extends RandomGeneratorAbstractTest { @ Override protected RandomGenerator makeGenerator ( ) { <START_BUG> return new Well1024a ( 1000 ) ; <END_BUG> } @ Test public void testReferenceCode ( ) { } }

Fix:
return new Well1024a ( 1001 ) ;
Buggy code:
public class LTStraight extends LTLineType { LTPoint a ; LTPoint b ; public LTStraight ( ) { } public LTStraight ( LTPoint a , LTPoint b ) throws TypeBuildException { } public LTStraight ( LTSegment segment ) { } public LTStraight ( LTPoint a , LTVector v ) throws TypeBuildException { } public LTStraight ( LTRay ray ) { } public LTStraight ( LTStraight straight ) { } @ Override public boolean equal ( LT2DType obj ) { } @ Override public boolean cross ( LT2DType obj ) { } @ Override public LT2DType [ ] crossPoint ( LT2DType obj ) { } @ Override public double distance ( LT2DType obj ) { } @ Override public LTVector getVector ( ) { } private boolean cross ( LTRay ray ) { } private boolean cross ( LTSegment segment ) { } private boolean cross ( LTStraight straight ) { } private LT2DType [ ] crossPoint ( LTRay ray ) { LTStraight s = new LTStraight ( ray ) ; LT2DType [ ] ret = this . crossPoint ( s ) ; LT2DType [ ] ans ; if ( ret == null ) ans = null ; else if ( ret [ 0 ] . getClass ( ) . equals ( LTStraight . class ) ) { ans = new LTRay [ 1 ] ; <START_BUG> ans [ 0 ] = new LTStraight ( ray ) ; <END_BUG> } else if ( ( ( LTPoint ) ( ret [ 0 ] ) ) . inside ( ray ) ) { ans = ret ; } else ans = null ; return ans ; } private LT2DType [ ] crossPoint ( LTSegment segment ) { } private LT2DType [ ] crossPoint ( LTStraight straight ) { } private double distance ( LTRay ray ) { } private double distance ( LTSegment segment ) { } private double distance ( LTStraight straight ) { } @ Override public boolean inside ( LTPoint point ) { } }

Fix:
ans [ 0 ] = new LTRay ( ray ) ;
Buggy code:
public class WSEndpointDeploymentUnit extends SimpleAttachable implements DeploymentUnit { private String deploymentName ; public WSEndpointDeploymentUnit ( ClassLoader loader , String context , Map < String , String > urlPatternToClassName , WebservicesMetaData metadata ) { } public WSEndpointDeploymentUnit ( ClassLoader loader , String context , Map < String , String > urlPatternToClassName , JBossWebMetaData jbossWebMetaData , WebservicesMetaData metadata ) { } private void addEndpoint ( JBossWebMetaData jbossWebMetaData , JAXWSDeployment jaxwsDeployment , String className , String urlPattern ) { if ( urlPattern == null ) { urlPattern = "//*" ; } else { urlPattern = urlPattern . trim ( ) ; if ( ! ( urlPattern . startsWith ( "//" ) ) ) { urlPattern = "//" + urlPattern ; } } <START_BUG> jaxwsDeployment . addEndpoint ( new POJOEndpoint ( className , urlPattern ) ) ; <END_BUG> } @ Override public ServiceName getServiceName ( ) { } @ Override public DeploymentUnit getParent ( ) { } @ Override public String getName ( ) { } @ Override public ServiceRegistry getServiceRegistry ( ) { } @ Override public ModelNode getDeploymentSubsystemModel ( String subsystemName ) { } @ Override public ModelNode createDeploymentSubModel ( String subsystemName , PathElement address ) { } }

Fix:
jaxwsDeployment . addEndpoint ( new POJOEndpoint ( className , null , urlPattern ) ) ;
Buggy code:
@ RunWith ( Arquillian . class ) @ ServerSetup ( EarPackagedDeploymentTestCase . EarPackagedDeploymentTestCaseSetup . class ) public class EarPackagedDeploymentTestCase extends ContainerResourceMgmtTestBase { static class EarPackagedDeploymentTestCaseSetup extends AbstractMgmtServerSetupTask { @ Override public void doSetup ( final ManagementClient managementClient ) throws Exception { String xml = FileUtils . readFile ( EarPackagedDeploymentTestCase . class , "ear_packaged.xml" ) ; <START_BUG> List < ModelNode > operations = xmlToModelOperations ( xml , CURRENT . getUriString ( ) , new ResourceAdapterSubsystemParser ( ) ) ; <END_BUG> executeOperation ( operationListToCompositeOperation ( operations ) ) ; } @ Override public void tearDown ( final ManagementClient managementClient , final String containerId ) throws Exception { } } @ Deployment public static EnterpriseArchive createDeployment ( ) throws Exception { } @ Resource ( mappedName = "java:jboss//name1" ) private MultipleConnectionFactory1 connectionFactory1 ; @ Resource ( mappedName = "java:jboss//Name3" ) private MultipleAdminObject1 adminObject1 ; @ Test public void testConfiguration ( ) throws Throwable { } }

Fix:
List < ModelNode > operations = xmlToModelOperations ( xml , RESOURCEADAPTERS_1_0 . getUriString ( ) , new ResourceAdapterSubsystemParser ( ) ) ;
Buggy code:
class SourceMethod extends Member implements IMethod { protected String [ ] fParameterTypes ; protected static final String [ ] fgEmptyList = new String [ ] { } ; protected SourceMethod ( JavaElement parent , String name , String [ ] parameterTypes ) { } public boolean equals ( Object o ) { } protected boolean equalsDOMNode ( IDOMNode node ) { } public int getElementType ( ) { } public String [ ] getExceptionTypes ( ) throws JavaModelException { } public String getHandleMemento ( ) { } protected char getHandleMementoDelimiter ( ) { } public int getNumberOfParameters ( ) { } public String [ ] getParameterNames ( ) throws JavaModelException { } public String [ ] getParameterTypes ( ) { } public IJavaElement getPrimaryElement ( boolean checkOwner ) { if ( checkOwner ) { CompilationUnit cu = ( ( CompilationUnit ) ( getAncestor ( IJavaElement . COMPILATION_UNIT ) ) ) ; <START_BUG> if ( ( cu . owner ) == ( DefaultWorkingCopyOwner . PRIMARY ) ) <END_BUG> return this ; } IJavaElement parent = fParent . getPrimaryElement ( false ) ; return ( ( IType ) ( parent ) ) . getMethod ( fName , fParameterTypes ) ; } public String getReturnType ( ) throws JavaModelException { } public String getSignature ( ) throws JavaModelException { } public boolean isConstructor ( ) throws JavaModelException { } public boolean isMainMethod ( ) throws JavaModelException { } public boolean isSimilar ( IMethod method ) { } public String readableName ( ) { } protected boolean signatureEquals ( IDOMMethod method ) { } protected void toStringInfo ( int tab , StringBuffer buffer , Object info ) { } private void toStringParameters ( StringBuffer buffer ) { } }

Fix:
if ( cu . isPrimary ( ) )
Buggy code:
public class ShellProcess { private DataOutputStream processIn ; private BufferedReader processOut ; private Process _subprocess ; private String [ ] command ; public ShellProcess ( String [ ] command ) { } public Number launch ( Map conf , TopologyContext context ) throws IOException { } public void destroy ( ) { } public void writeMessage ( Object msg ) throws IOException { } private void writeString ( String str ) throws IOException { } public JSONObject readMessage ( ) throws IOException { } private String readString ( ) throws IOException { StringBuilder line = new StringBuilder ( ) ; while ( true ) { String subline = processOut . readLine ( ) ; if ( subline == null ) <START_BUG> throw new RuntimeException ( ( "Pipe<seq2seq4repair_space>to<seq2seq4repair_space>subprocess<seq2seq4repair_space>seems<seq2seq4repair_space>to<seq2seq4repair_space>be<seq2seq4repair_space>broken!<seq2seq4repair_space>Currently<seq2seq4repair_space>read<seq2seq4repair_space>output:<seq2seq4repair_space>" + ( line . toString ( ) ) ) ) ; <END_BUG> if ( subline . equals ( "end" ) ) { break ; } if ( ( line . length ( ) ) != 0 ) { line . append ( "\n" ) ; } line . append ( subline ) ; } return line . toString ( ) ; } }

Fix:
throw new RuntimeException ( "Pipe<seq2seq4repair_space>to<seq2seq4repair_space>subprocess<seq2seq4repair_space>seems<seq2seq4repair_space>to<seq2seq4repair_space>be<seq2seq4repair_space>broken!" ) ;
Buggy code:
public final class AddConnectorUpdate extends AbstractRemotingSubsystemUpdate < Void > { private static final long serialVersionUID = - 1238913680118311381L ; private final String name ; private final String socketBinding ; private SaslElement saslElement ; private String authenticationProvider ; private final Map < String , String > properties = new HashMap < String , String > ( ) ; public AddConnectorUpdate ( String name , String socketBinding ) { } protected < P > void applyUpdate ( UpdateContext updateContext , UpdateResultHandler < ? super Void , P > resultHandler , P param ) { <START_BUG> final BatchBuilder batchBuilder = updateContext . getBatchBuilder ( ) ; <END_BUG> final OptionMap . Builder builder = OptionMap . builder ( ) ; if ( ( saslElement ) != null ) saslElement . applyTo ( builder ) ; final ConnectorService connectorService = new ConnectorService ( ) ; connectorService . setOptionMap ( builder . getMap ( ) ) ; final UpdateResultHandler . ServiceStartListener < P > listener = new UpdateResultHandler . ServiceStartListener < P > ( resultHandler , param ) ; final ServiceName connectorName = ConnectorElement . connectorName ( name ) ; try { batchBuilder . addService ( connectorName , connectorService ) . addDependency ( connectorName . append ( "auth-provider" ) , ServerAuthenticationProvider . class , connectorService . getAuthenticationProviderInjector ( ) ) . addDependency ( JBOSS_REMOTING_ENDPOINT , Endpoint . class , connectorService . getEndpointInjector ( ) ) . addListener ( listener ) . setInitialMode ( ACTIVE ) . install ( ) ; batchBuilder . install ( ) ; } catch ( ServiceRegistryException e ) { resultHandler . handleFailure ( e , param ) ; } } public AbstractSubsystemUpdate < RemotingSubsystemElement , ? > getCompensatingUpdate ( RemotingSubsystemElement original ) { } protected void applyUpdate ( RemotingSubsystemElement element ) throws UpdateFailedException { } public void setSaslElement ( SaslElement saslElement ) { } public void setAuthenticationProvider ( String authenticationProvider ) { } public Map < String , String > getProperties ( ) { } }

Fix:
final BatchBuilder batchBuilder = updateContext . getServiceTarget ( ) ;
Buggy code:
public abstract class StartLevelHandler implements OperationStepHandler { public static final StartLevelHandler READ_HANDLER = new StartLevelHandler ( ) { @ Override void invokeOperation ( StartLevel startLevel , OperationContext context , ModelNode operation ) { } } ; public static final StartLevelHandler WRITE_HANDLER = new StartLevelHandler ( ) { @ Override void invokeOperation ( StartLevel startLevel , OperationContext context , ModelNode operation ) { } } ; @ Override public void execute ( OperationContext context , ModelNode operation ) throws OperationFailedException { ServiceController < ? > controller = context . getServiceRegistry ( false ) . getService ( START_LEVEL ) ; if ( ( controller != null ) && ( ( controller . getState ( ) ) == ( State . UP ) ) ) { StartLevel startLevel = ( ( StartLevel ) ( controller . getValue ( ) ) ) ; invokeOperation ( startLevel , context , operation ) ; } else { context . getResult ( ) . set ( new ModelNode ( ) ) ; } <START_BUG> context . completeStep ( ) ; <END_BUG> } abstract void invokeOperation ( StartLevel sls , OperationContext context , ModelNode operation ) { } }

Fix:
context . completeStep ( NOOP_ROLLBACK_HANDLER ) ;
Buggy code:
public class Maze { private Node [ ] [ ] maze ; private ArrayList < Maze . MazePoint > mazePoints ; public Maze ( int rows , int cols ) { } private void init ( ) { } private void addFeature ( char feature , char replace ) { <START_BUG> for ( int r = 0 ; r < 30 ; r ++ ) { <END_BUG> int row = ( ( int ) ( ( Math . random ( ) ) * ( maze . length ) ) ) ; int col = ( ( int ) ( ( Math . random ( ) ) * ( maze . length ) ) ) ; if ( ( ( maze [ row ] [ col ] . getType ( ) ) == replace ) && ( ( maze [ row ] [ col ] . getType ( ) ) != '<seq2seq4repair_space>' ) ) { if ( ( feature == 'L' ) && ( r <= 3 ) ) { maze [ row ] [ col ] . setType ( SWORD ) ; break ; } switch ( feature ) { case 'W' : maze [ row ] [ col ] . setType ( SWORD ) ; break ; case 'S' : maze [ row ] [ col ] . setType ( SPRAY ) ; break ; case 'T' : maze [ row ] [ col ] . setType ( TOOTHPICK ) ; break ; case '?' : maze [ row ] [ col ] . setType ( PRISONER ) ; break ; case 'B' : maze [ row ] [ col ] . setType ( BOMB ) ; break ; } } } } private void buildMaze ( ) { } public Node [ ] [ ] getMaze ( ) { } private class MazePoint { private Integer r ; private Integer c ; private Maze . MazePoint parent ; public MazePoint ( int x , int y , Maze . MazePoint p ) { } public Maze . MazePoint opposite ( ) { } } No newline ; at end ; of file ; }

Fix:
for ( int r = 0 ; r < 40 ; r ++ ) {
Buggy code:
public class DB_Index { public static void doIndexes ( Connection conn ) throws SQLException { Statement stmt = conn . createStatement ( ) ; ResultSet rs = stmt . executeQuery ( ( "SELECT<seq2seq4repair_space>TABLEID,<seq2seq4repair_space>CONGLOMERATENAME,<seq2seq4repair_space>" + ( "DESCRIPTOR,<seq2seq4repair_space>SCHEMAID,<seq2seq4repair_space>ISINDEX,<seq2seq4repair_space>ISCONSTRAINT<seq2seq4repair_space>FROM<seq2seq4repair_space>SYS.SYSCONGLOMERATES<seq2seq4repair_space>" + "ORDER<seq2seq4repair_space>BY<seq2seq4repair_space>TABLEID" ) ) ) ; boolean firstTime = true ; while ( rs . next ( ) ) { if ( ( ! ( rs . getBoolean ( 5 ) ) ) || ( rs . getBoolean ( 6 ) ) ) continue ; String tableId = rs . getString ( 1 ) ; String tableName = dblook . lookupTableId ( tableId ) ; if ( tableName == null ) continue ; else if ( dblook . isExcludedTable ( tableName ) ) continue ; String iSchema = dblook . lookupSchemaId ( rs . getString ( 4 ) ) ; if ( dblook . isIgnorableSchema ( iSchema ) ) continue ; if ( firstTime ) { Logs . reportString ( "----------------------------------------------" ) ; <START_BUG> Logs . reportMessage ( "CSLOOK_IndexesHeader" ) ; <END_BUG> Logs . reportString ( "----------------------------------------------\n" ) ; } String iName = dblook . addQuotes ( dblook . expandDoubleQuotes ( rs . getString ( 2 ) ) ) ; iName = ( iSchema + "." ) + iName ; StringBuffer createIndexString = DB_Index . createIndex ( iName , tableName , tableId , rs . getString ( 3 ) ) ; Logs . writeToNewDDL ( createIndexString . toString ( ) ) ; Logs . writeStmtEndToNewDDL ( ) ; Logs . writeNewlineToNewDDL ( ) ; firstTime = false ; } rs . close ( ) ; stmt . close ( ) ; } private static StringBuffer createIndex ( String ixName , String tableName , String tableId , String ixDescribe ) throws SQLException { } }

Fix:
Logs . reportMessage ( "DBLOOK_IndexesHeader" ) ;
Buggy code:
public class CommandMenu extends JMenu implements CommandListener , ActionListener { private HashMap hm ; public CommandMenu ( String name ) { } public synchronized void add ( Command command ) { } public synchronized void add ( Command command , MenuShortcut shortcut ) { } public synchronized void addCheckItem ( Command command ) { } protected void addMenuItem ( Command command , JMenuItem m ) { } public synchronized void remove ( Command command ) { } public synchronized void remove ( MenuItem item ) { } public synchronized void enable ( String name , boolean state ) { for ( int i = 0 ; i < ( getItemCount ( ) ) ; i ++ ) { JMenuItem item = getItem ( i ) ; <START_BUG> if ( name . equals ( item . getLabel ( ) ) ) { <END_BUG> item . setEnabled ( state ) ; return ; } } } public synchronized void checkEnabled ( ) { } public void actionPerformed ( ActionEvent e ) { } public void commandExecuted ( EventObject commandEvent ) { } public void commandExecutable ( EventObject commandEvent ) { } public void commandNotExecutable ( EventObject commandEvent ) { } }

Fix:
if ( name . equals ( item . getText ( ) ) ) {
Buggy code:
public class MemoryConnection implements MemoryConnectionInterface { private final DataConnection connection ; public MemoryConnection ( DataConnection connection ) { } @ Override public DataConnection getConnection ( ) { } @ Override public byte [ ] read ( int address , int count ) throws IOException , TimeoutException { } @ Override public byte [ ] read ( MemoryLocation location ) throws IOException , TimeoutException { } @ Override public byte [ ] read ( MemoryLocation location , int offset , int count ) throws IOException , TimeoutException { } byte [ ] read ( final MemoryRead memoryRead ) throws IOException , TimeoutException { } @ Override public void write ( int address , byte [ ] data ) throws IOException , TimeoutException { final int endAddress = address + ( data . length ) ; final int maxBlockSize = 12 ; for ( int addr = address ; addr < endAddress ; addr += maxBlockSize ) { int blockSize = Math . min ( ( endAddress - addr ) , maxBlockSize ) ; int offs = addr - address ; byte [ ] dataBlock = Arrays . copyOfRange ( data , offs , ( offs + blockSize ) ) ; byte [ ] currentBlock = read ( addr , blockSize ) ; if ( Arrays . equals ( dataBlock , currentBlock ) ) continue ; <START_BUG> connection . query ( new MemoryWrite ( addr , dataBlock ) ) ; <END_BUG> currentBlock = read ( addr , blockSize ) ; if ( ! ( Arrays . equals ( dataBlock , currentBlock ) ) ) throw new IOException ( "memory<seq2seq4repair_space>write:<seq2seq4repair_space>verify<seq2seq4repair_space>failed" ) ; } } @ Override public void write ( MemoryLocation location , byte [ ] data ) throws IOException , TimeoutException { } }

Fix:
connection . send ( new MemoryWrite ( addr , dataBlock ) ) ;
Buggy code:
public class LdapConnectionWriteAttributeHandler extends AbstractWriteAttributeHandler < Void > { public LdapConnectionWriteAttributeHandler ( ) { } void registerAttributes ( final ManagementResourceRegistration registration ) { } @ Override protected boolean applyUpdateToRuntime ( final OperationContext context , final ModelNode operation , final String attributeName , final ModelNode resolvedValue , final ModelNode currentValue , final HandbackHolder < Void > handbackHolder ) throws OperationFailedException { } @ Override protected void revertUpdateToRuntime ( final OperationContext context , final ModelNode operation , final String attributeName , final ModelNode valueToRestore , final ModelNode valueToRevert , final Void handback ) throws OperationFailedException { } private void updateLdapConnectionService ( final OperationContext context , final ModelNode operation , final ModelNode model ) throws OperationFailedException { PathAddress address = PathAddress . pathAddress ( operation . require ( OP_ADDR ) ) ; String name = address . getLastElement ( ) . getValue ( ) ; <START_BUG> ServiceName svcName = BASE_SERVICE_NAME . append ( name ) ; <END_BUG> ServiceRegistry registry = context . getServiceRegistry ( true ) ; ServiceController < ? > controller = registry . getService ( svcName ) ; if ( controller != null ) { final ModelNode resolvedConfig = LdapConnectionAddHandler . createResolvedLdapConfiguration ( context , model ) ; LdapConnectionManagerService service = LdapConnectionManagerService . class . cast ( controller . getValue ( ) ) ; service . setResolvedConfiguration ( resolvedConfig ) ; } else { } } }

Fix:
ServiceName svcName = ServiceUtil . createServiceName ( name ) ;
Buggy code:
public class OutpostCore implements Runnable { public boolean isCanceled = false ; public boolean isSucceeded = false ; public Location signBlockLocation ; public Player capturer ; public String outpost ; public String capturingGroup ; public String owningGroup ; public int stage = 10 ; public int decreaseIn = 2 ; public OutpostCore ( Block sign , Player capturer ) { } private Block getSignBlock ( ) { } public void remove ( ) { } public void capture ( ) { } public void run ( ) { if ( isCanceled ) { remove ( ) ; return ; } Block signBlock = getSignBlock ( ) ; if ( ( signBlock . getState ( ) ) instanceof Sign ) { <START_BUG> if ( ( signBlock . getLocation ( ) . distance ( capturer . getLocation ( ) ) ) > ( PvPlus . getInt ( "doors.range" ) ) ) { <END_BUG> capturer . sendMessage ( ( ( ChatColor . RED ) + "You've<seq2seq4repair_space>moved<seq2seq4repair_space>out<seq2seq4repair_space>of<seq2seq4repair_space>range<seq2seq4repair_space>of<seq2seq4repair_space>the<seq2seq4repair_space>core!" ) ) ; remove ( ) ; return ; } if ( ( stage ) < 1 ) { capture ( ) ; return ; } if ( ( decreaseIn ) > 0 ) { ( decreaseIn ) -- ; return ; } else { decreaseIn = 2 ; } ( stage ) -- ; String stageString = "§4" ; for ( int i = 0 ; i <= ( stage ) ; i ++ ) { stageString += "|" ; } stageString += "§2" ; for ( int i = 10 - ( stage ) ; i >= 0 ; i -- ) { stageString += "|" ; } Sign signSign = ( ( Sign ) ( signBlock . getState ( ) ) ) ; signSign . setLine ( 1 , stageString ) ; signSign . update ( ) ; } else { remove ( ) ; } } }

Fix:
if ( ( signBlock . getLocation ( ) . distance ( capturer . getLocation ( ) ) ) > ( PvPlus . getInt ( "range" ) ) ) {
Buggy code:
public class FilteredComboTree extends FilteredTree { private Combo filterCombo ; private static final String SEARCHHISTORY = "search" ; private static final int maxNumItems = 20 ; public FilteredComboTree ( Composite parent , int treeStyle ) { } public FilteredComboTree ( Composite parent , int treeStyle , PatternItemFilter filter ) { } protected void createFilterControl ( Composite parent ) { filterCombo = new Combo ( parent , ( ( SWT . DROP_DOWN ) | ( SWT . BORDER ) ) ) ; filterCombo . setFont ( parent . getFont ( ) ) ; getPreferenceSearchHistory ( ) ; filterCombo . addTraverseListener ( new TraverseListener ( ) { public void keyTraversed ( TraverseEvent e ) { if ( ( e . detail ) == ( SWT . TRAVERSE_RETURN ) ) { e . doit = false ; if ( ( getViewer ( ) . getTree ( ) . getItemCount ( ) ) == 0 ) { Display . getCurrent ( ) . beep ( ) ; setFilterText ( "" ) ; } else { getViewer ( ) . getTree ( ) . setFocus ( ) ; } } } } ) ; filterCombo . addFocusListener ( new FocusAdapter ( ) { public void focusLost ( FocusEvent e ) { String [ ] textValues = filterCombo . getItems ( ) ; String newText = filterCombo . getText ( ) ; <START_BUG> if ( ( newText . equals ( "" ) ) && ( newText . equals ( initialText ) ) ) <END_BUG> return ; for ( int i = 0 ; i < ( textValues . length ) ; i ++ ) { if ( textValues [ i ] . equals ( newText ) ) return ; } if ( ( textValues . length ) >= ( FilteredComboTree . maxNumItems ) ) filterCombo . remove ( ( ( FilteredComboTree . maxNumItems ) - 1 ) ) ; filterCombo . add ( newText , 0 ) ; } } ) ; filterCombo . addSelectionListener ( new SelectionAdapter ( ) { public void widgetSelected ( SelectionEvent e ) { textChanged ( ) ; } } ) ; filterCombo . addDisposeListener ( new DisposeListener ( ) { public void widgetDisposed ( DisposeEvent e ) { saveDialogSettings ( ) ; } } ) ; filterCombo . getAccessible ( ) . addAccessibleListener ( getAccessibleListener ( ) ) ; } public Control getFilterControl ( ) { } protected String getFilterControlText ( ) { } protected void setFilterText ( String string ) { } protected void selectAll ( ) { } public Combo getFilterCombo ( ) { } protected String getFilterText ( ) { } private IDialogSettings getDialogSettings ( ) { } public void getPreferenceSearchHistory ( ) { } private void saveDialogSettings ( ) { } }

Fix:
if ( ( newText . equals ( "" ) ) || ( newText . equals ( initialText ) ) )
Buggy code:
@ Service public class DefaultStackService implements StackService { private static final Logger LOGGER = LoggerFactory . getLogger ( DefaultStackService . class ) ; @ Autowired private StackRepository stackRepository ; @ Autowired private TemplateRepository templateRepository ; @ Autowired private RetryingStackUpdater stackUpdater ; @ Autowired private Reactor reactor ; @ Autowired private ClusterRepository clusterRepository ; @ Autowired private AmbariClusterConnector ambariClusterConnector ; @ Resource private Map < CloudPlatform , ProvisionSetup > provisionSetups ; @ Override public Set < Stack > retrievePrivateStacks ( CbUser user ) { } @ Override public Set < Stack > retrieveAccountStacks ( CbUser user ) { } @ Override public Stack get ( Long id ) { } @ Override public Stack get ( String ambariAddress ) { } public Stack getPrivateStack ( String name , CbUser cbUser ) { } public Stack getPublicStack ( String name , CbUser cbUser ) { } @ Override public void delete ( String name , CbUser user ) { } @ Override public Stack create ( CbUser user , Stack stack ) { } @ Override public void delete ( Long id , CbUser user ) { } @ Override public void updateStatus ( Long stackId , StatusRequest status ) { } @ Override public void updateNodeCount ( Long stackId , HostGroupAdjustmentJson hostGroupAdjustmentJson ) { } @ Override public Set < InstanceMetaData > getMetaData ( String hash ) { } private void delete ( Stack stack , CbUser user ) { MDCBuilder . buildMdcContext ( stack ) ; DefaultStackService . LOGGER . info ( "Stack<seq2seq4repair_space>delete<seq2seq4repair_space>requested." ) ; if ( ( ! ( user . getUserId ( ) . equals ( stack . getOwner ( ) ) ) ) && ( ! ( user . getRoles ( ) . contains ( ADMIN ) ) ) ) { throw new BadRequestException ( "Public<seq2seq4repair_space>stacks<seq2seq4repair_space>can<seq2seq4repair_space>be<seq2seq4repair_space>deleted<seq2seq4repair_space>only<seq2seq4repair_space>by<seq2seq4repair_space>account<seq2seq4repair_space>admins<seq2seq4repair_space>or<seq2seq4repair_space>owners." ) ; } else { DefaultStackService . LOGGER . info ( "Publishing<seq2seq4repair_space>{}<seq2seq4repair_space>event." , DELETE_REQUEST_EVENT ) ; <START_BUG> reactor . notify ( DELETE_REQUEST_EVENT , Event . wrap ( new com . sequenceiq . cloudbreak . service . stack . event . StackDeleteRequest ( stack . getTemplate ( ) . cloudPlatform ( ) , stack . getId ( ) ) ) ) ; <END_BUG> } } private String generateHash ( Stack stack ) { } }

Fix:
reactor . notify ( DELETE_REQUEST_EVENT , Event . wrap ( new com . sequenceiq . cloudbreak . service . stack . event . StackDeleteRequest ( stack . cloudPlatform ( ) , stack . getId ( ) ) ) ) ;
Buggy code:
@ SuppressWarnings ( "unchecked" ) public class OCommandExecutorSQLAlterClass extends OCommandExecutorSQLAbstract implements OCommandDistributedReplicateRequest { public static final String KEYWORD_ALTER = "ALTER" ; public static final String KEYWORD_CLASS = "CLASS" ; private String className ; private ATTRIBUTES attribute ; private String value ; private boolean unsafe = false ; public OCommandExecutorSQLAlterClass parse ( final OCommandRequest iRequest ) { } public Object execute ( final Map < Object , Object > iArgs ) { final ODatabaseDocument database = getDatabase ( ) ; if ( ( attribute ) == null ) throw new OCommandExecutionException ( "Cannot<seq2seq4repair_space>execute<seq2seq4repair_space>the<seq2seq4repair_space>command<seq2seq4repair_space>because<seq2seq4repair_space>it<seq2seq4repair_space>has<seq2seq4repair_space>not<seq2seq4repair_space>been<seq2seq4repair_space>parsed<seq2seq4repair_space>yet" ) ; final OClassImpl cls = ( ( OClassImpl ) ( database . getMetadata ( ) . getSchema ( ) . getClass ( className ) ) ) ; if ( cls == null ) throw new OCommandExecutionException ( ( ( "Cannot<seq2seq4repair_space>alter<seq2seq4repair_space>class<seq2seq4repair_space>'" + ( className ) ) + "'<seq2seq4repair_space>because<seq2seq4repair_space>not<seq2seq4repair_space>found" ) ) ; <START_BUG> if ( ( ! ( unsafe ) ) && ( cls . isSubClassOf ( "E" ) ) ) <END_BUG> throw new OCommandExecutionException ( ( ( "Cannot<seq2seq4repair_space>alter<seq2seq4repair_space>class<seq2seq4repair_space>'" + ( className ) ) + "'<seq2seq4repair_space>because<seq2seq4repair_space>is<seq2seq4repair_space>an<seq2seq4repair_space>Edge<seq2seq4repair_space>class<seq2seq4repair_space>and<seq2seq4repair_space>could<seq2seq4repair_space>break<seq2seq4repair_space>vertices.<seq2seq4repair_space>Use<seq2seq4repair_space>UNSAFE<seq2seq4repair_space>if<seq2seq4repair_space>you<seq2seq4repair_space>want<seq2seq4repair_space>to<seq2seq4repair_space>force<seq2seq4repair_space>it" ) ) ; cls . set ( attribute , value ) ; return null ; } public String getSyntax ( ) { } @ Override public boolean involveSchema ( ) { } }

Fix:
if ( ( ( ! ( unsafe ) ) && ( ( attribute ) == ( ATTRIBUTES . NAME ) ) ) && ( cls . isSubClassOf ( "E" ) ) )
Buggy code:
public class BaseChannel extends TransactionSharedObject implements IChannel { public static final String RECEIVER_ID_PROPERTY = BaseChannel . class . getName ( ) ; static class ChannelMsg implements Serializable { private static final long serialVersionUID = 9065358269778864152L ; byte [ ] channelData = null ; ChannelMsg ( ) { } ChannelMsg ( byte [ ] data ) { } byte [ ] getData ( ) { } public String toString ( ) { } } protected IChannelListener listener ; public BaseChannel ( ISharedObjectTransactionConfig config , IChannelListener listener ) { } public BaseChannel ( ) { } protected void setChannelListener ( IChannelListener l ) { } protected void initialize ( ) throws SharedObjectInitException { } public Object getAdapter ( Class clazz ) { } private IChannelGroupJoinEvent createChannelGroupJoinEvent ( final boolean hasJoined , final ID targetID ) { } private IChannelGroupDepartEvent createChannelGroupDepartEvent ( final boolean hasJoined , final ID targetID ) { } private Event handleMessageEvent ( final ISharedObjectMessageEvent event ) { } public void sendMessage ( byte [ ] message ) throws ECFException { } public void sendMessage ( ID receiver , byte [ ] message ) throws ECFException { } public IChannelListener getListener ( ) { } protected void receiveUndeliveredChannelEvent ( IChannelEvent channelEvent ) { } protected ReplicaSharedObjectDescription getReplicaDescription ( ID targetContainerID ) { } protected void initializeReplicaChannel ( ) throws SharedObjectInitException { Map properties = getConfig ( ) . getProperties ( ) ; ID rcvr = null ; try { rcvr = ( ( ID ) ( properties . get ( BaseChannel . RECEIVER_ID_PROPERTY ) ) ) ; } catch ( ClassCastException e ) { throw new SharedObjectInitException ( "Bad<seq2seq4repair_space>RECEIVER_ID_PROPERTY<seq2seq4repair_space>for<seq2seq4repair_space>replica.<seq2seq4repair_space>Cannot<seq2seq4repair_space>be<seq2seq4repair_space>cast<seq2seq4repair_space>to<seq2seq4repair_space>org.eclipse.ecf.core.identity.ID<seq2seq4repair_space>type" ) ; } IChannelListener l = null ; if ( rcvr != null ) { IChannelContainer container = ( ( IChannelContainer ) ( getContext ( ) . getAdapter ( IChannelContainer . class ) ) ) ; if ( container == null ) throw new SharedObjectInitException ( "channel<seq2seq4repair_space>container<seq2seq4repair_space>is<seq2seq4repair_space>null//not<seq2seq4repair_space>available" ) ; final IChannel receiver = container . getChannel ( rcvr ) ; if ( receiver == null ) throw new SharedObjectInitException ( "receiver<seq2seq4repair_space>channel<seq2seq4repair_space>is<seq2seq4repair_space>null//not<seq2seq4repair_space>available" ) ; setChannelListener ( receiver . getListener ( ) ) ; } <START_BUG> if ( l == null ) { <END_BUG> setChannelListener ( new IChannelListener ( ) { public void handleChannelEvent ( IChannelEvent event ) { receiveUndeliveredChannelEvent ( event ) ; } } ) ; } else { this . listener = l ; } } }

Fix:
if ( ( listener ) == null ) {
Buggy code:
class StormServerHandler extends SimpleChannelUpstreamHandler { private static final Logger LOG = LoggerFactory . getLogger ( StormServerHandler . class ) ; Server server ; private AtomicInteger failure_count ; StormServerHandler ( Server server ) { } @ Override public void channelConnected ( ChannelHandlerContext ctx , ChannelStateEvent e ) { } @ Override public void messageReceived ( ChannelHandlerContext ctx , MessageEvent e ) { } @ Override public void exceptionCaught ( ChannelHandlerContext ctx , ExceptionEvent e ) { <START_BUG> e . getCause ( ) . printStackTrace ( ) ; <END_BUG> server . closeChannel ( e . getChannel ( ) ) ; } }

Fix:
StormServerHandler . LOG . error ( "server<seq2seq4repair_space>errors<seq2seq4repair_space>in<seq2seq4repair_space>handling<seq2seq4repair_space>the<seq2seq4repair_space>request" , e . getCause ( ) ) ;
Buggy code:
public class Utils { public static final int DEFAULT_STREAM_ID = 1 ; public static byte [ ] serialize ( Object obj ) { } public static Object deserialize ( byte [ ] serialized ) { } public static < T > String join ( Iterable < T > coll , String sep ) { } public static void sleep ( long millis ) { } public static Map readYamlConfig ( String path ) { } public static Map findAndReadConfigFile ( String name , boolean mustExist ) { <START_BUG> InputStream is = Object . class . getResourceAsStream ( ( "//" + name ) ) ; <END_BUG> if ( is == null ) { if ( mustExist ) throw new RuntimeException ( ( "Could<seq2seq4repair_space>not<seq2seq4repair_space>find<seq2seq4repair_space>config<seq2seq4repair_space>file<seq2seq4repair_space>on<seq2seq4repair_space>classpath<seq2seq4repair_space>" + name ) ) ; else return new HashMap ( ) ; } Map ret = ( ( Map ) ( YAML . load ( new InputStreamReader ( is ) ) ) ) ; if ( ret == null ) ret = new HashMap ( ) ; return new HashMap ( ret ) ; } public static Map findAndReadConfigFile ( String name ) { } public static Map readDefaultConfig ( ) { } public static Map readStormConfig ( ) { } public static Object getSetComponentObject ( ComponentObject obj ) { } public static < S , T > T get ( Map < S , T > m , S key , T def ) { } public static List < Object > tuple ( Object ... values ) { } public static void downloadFromMaster ( Map conf , String file , String localFile ) throws IOException , TException { } public static IFn loadClojureFn ( String namespace , String name ) { } }

Fix:
InputStream is = Utils . class . getResourceAsStream ( ( "//" + name ) ) ;
Buggy code:
public class ShapeAsPointsBuilder { private final List < GeoPoint > points ; private final Geodesic wgs84 ; public ShapeAsPointsBuilder ( ) { } public ShapeAsPointsBuilder ( @ NonNull List < GeoPoint > startList ) { } public ShapeAsPointsBuilder GRC ( @ NonNull GeoPoint geoPoint ) { } public ShapeAsPointsBuilder CWA ( @ NonNull GeoPoint startPoint , @ NonNull GeoPoint centerPoint , @ NonNull GeoPoint endPoint , double radius ) { points . add ( startPoint ) ; GeodesicData f = wgs84 . Inverse ( centerPoint . getLatitude ( ) , centerPoint . getLongitude ( ) , startPoint . getLatitude ( ) , startPoint . getLongitude ( ) ) ; GeodesicData t = wgs84 . Inverse ( centerPoint . getLatitude ( ) , centerPoint . getLongitude ( ) , endPoint . getLatitude ( ) , endPoint . getLongitude ( ) ) ; double ffaz = f . azi1 ; double tfaz = ( ( ( ffaz < 0 ) && ( ( t . azi1 ) < 0 ) ) || ( ( t . azi1 ) > 0 ) ) ? t . azi1 : 360 + ( t . azi1 ) ; <START_BUG> while ( ( ( int ) ( ffaz ) ) != ( Math . abs ( ( ( int ) ( tfaz ) ) ) ) ) { <END_BUG> GeodesicData llb = wgs84 . Direct ( centerPoint . getLatitude ( ) , centerPoint . getLongitude ( ) , ffaz , f . s12 ) ; points . add ( new GeoPoint ( llb . lat2 , llb . lon2 ) ) ; ffaz += 1 ; if ( ffaz > 360 ) { ffaz -= 360 ; } } points . add ( endPoint ) ; return this ; } public ShapeAsPointsBuilder CCA ( @ NonNull GeoPoint startPoint , @ NonNull GeoPoint centerPoint , @ NonNull GeoPoint endPoint , double radius ) { } public ShapeAsPointsBuilder CIR ( @ NonNull GeoPoint centerPoint , double dist ) { } protected ShapeAsPointsBuilder RHL ( ) { } protected ShapeAsPointsBuilder FNT ( ) { } public List < GeoPoint > toList ( ) { } }

Fix:
while ( ( ( int ) ( ffaz ) ) != ( ( int ) ( tfaz ) ) ) {