nus-yam/ex-repair huggingface dataset:
Buggy code:
public final class JavaConventions { private static final char fgDot = '.' ; private static final Scanner SCANNER = new Scanner ( ) ; private JavaConventions ( ) { } private static int indexOfEnclosingPath ( IPath checkedPath , IPath [ ] paths , int pathCount ) { } private static int indexOfMatchingPath ( IPath checkedPath , IPath [ ] paths , int pathCount ) { } private static int indexOfNestedPath ( IPath checkedPath , IPath [ ] paths , int pathCount ) { } public static boolean isOverlappingRoots ( IPath rootPath1 , IPath rootPath2 ) { } private static synchronized char [ ] scannedIdentifier ( String id ) { } public static IStatus validateCompilationUnitName ( String name ) { } public static IStatus validateClassFileName ( String name ) { if ( name == null ) { return new Status ( IStatus . ERROR , JavaCore . PLUGIN_ID , ( - 1 ) , Util . bind ( "convention.classFile.nullName" ) , null ) ; } if ( ! ( Util . isClassFileName ( name ) ) ) { return new Status ( IStatus . ERROR , JavaCore . PLUGIN_ID , ( - 1 ) , Util . bind ( "convention.classFile.notClassFileName" ) , null ) ; } String identifier ; int index ; index = name . lastIndexOf ( '.' ) ; if ( index == ( - 1 ) ) { <START_BUG> return new Status ( IStatus . ERROR , JavaCore . PLUGIN_ID , ( - 1 ) , Util . bind ( "convention.classFile.notJavaName" ) , null ) ; <END_BUG> } identifier = name . substring ( 0 , index ) ; IStatus status = JavaConventions . validateIdentifier ( identifier ) ; if ( ! ( status . isOK ( ) ) ) { return status ; } status = ResourcesPlugin . getWorkspace ( ) . validateName ( name , IResource . FILE ) ; if ( ! ( status . isOK ( ) ) ) { return status ; } return JavaModelStatus . VERIFIED_OK ; } public static IStatus validateFieldName ( String name ) { } public static IStatus validateIdentifier ( String id ) { } public static IStatus validateImportDeclaration ( String name ) { } public static IStatus validateJavaTypeName ( String name ) { } public static IStatus validateMethodName ( String name ) { } public static IStatus validatePackageName ( String name ) { } public static IJavaModelStatus validateClasspath ( IJavaProject javaProject , IClasspathEntry [ ] rawClasspath , IPath projectOutputLocation ) { } public static IJavaModelStatus validateClasspathEntry ( IJavaProject javaProject , IClasspathEntry entry , boolean checkSourceAttachment ) { } }

Fix:
return new Status ( IStatus . ERROR , JavaCore . PLUGIN_ID , ( - 1 ) , Util . bind ( "convention.classFile.notClassFileName" ) , null ) ;
Buggy code:
public class TestQueryExpressionSplit extends BaseQueryTest { public TestQueryExpressionSplit ( String test ) { } public void testSimple ( ) { assertEquals ( new String [ ] { "foo()<seq2seq4repair_space>bar(boo)" } , Filters . splitExpressions ( "foo()<seq2seq4repair_space>bar(boo)" , ',' , 3 ) ) ; <START_BUG> assertEquals ( new String [ ] { "foo()<seq2seq4repair_space>bar(boo)" , "biz()" , "baz(boo)" } , Filters . splitExpressions ( "foo()<seq2seq4repair_space>bar(boo),<seq2seq4repair_space>bizbaz(boo)" , ',' , 3 ) ) ; <END_BUG> } public void testCommaInString ( ) { } public void testCommaInFunction ( ) { } public void testEscapedString ( ) { } private void assertEquals ( String [ ] ans , List test ) { } }

Fix:
assertEquals ( new String [ ] { "foo()<seq2seq4repair_space>bar(boo)" , "biz()" , "baz(boo)" } , Filters . splitExpressions ( "foo()<seq2seq4repair_space>bar(boo),<seq2seq4repair_space>biz(),<seq2seq4repair_space>baz(boo)" , ',' , 3 ) ) ;
Buggy code:
public abstract class RatingPanel extends Panel < Integer > { private final class RatingStarBar extends Loop { private static final long serialVersionUID = 1L ; private RatingStarBar ( MarkupContainer parent , String id , IModel < Integer > model ) { } @ Override protected void populateItem ( LoopItem item ) { AjaxFallbackLink link = new AjaxFallbackLink ( item , "link" ) { private static final long serialVersionUID = 1L ; @ Override public boolean isEnabled ( ) { <START_BUG> return ! ( ( ( Boolean ) ( hasVoted . getObject ( RatingPanel . this ) ) ) . booleanValue ( ) ) ; <END_BUG> } @ Override public void onClick ( AjaxRequestTarget target ) { LoopItem item = ( ( LoopItem ) ( getParent ( ) ) ) ; onRated ( ( ( item . getIteration ( ) ) + 1 ) , target ) ; if ( target != null ) { target . addComponent ( RatingPanel . this . get ( "rater" ) ) ; } } } ; int iteration = item . getIteration ( ) ; new wicket . markup . html . WebMarkupContainer ( link , "star" ) . add ( new SimpleAttributeModifier ( "src" , ( onIsStarActive ( iteration ) ? getActiveStarUrl ( iteration ) : getInactiveStarUrl ( iteration ) ) ) ) ; } } public static final ResourceReference STAR0 = new PackageResourceReference ( RatingPanel . class , "star0.gif" ) ; public static final ResourceReference STAR1 = new PackageResourceReference ( RatingPanel . class , "star1.gif" ) ; private static final long serialVersionUID = 1L ; private IModel hasVoted ; private IModel < Integer > nrOfStars = new wicket . model . Model < Integer > ( Integer . valueOf ( 5 ) ) ; private IModel nrOfVotes ; private Component ratingLabel ; public RatingPanel ( MarkupContainer parent , String id ) { } public RatingPanel ( MarkupContainer parent , String id , IModel < Integer > rating ) { } public RatingPanel ( MarkupContainer parent , String id , IModel < Integer > rating , IModel < Integer > nrOfStars , IModel < Integer > nrOfVotes , IModel < Boolean > hasVoted , boolean addDefaultCssStyle ) { } public RatingPanel ( MarkupContainer parent , String id , IModel < Integer > rating , int nrOfStars , boolean addDefaultCssStyle ) { } public RatingPanel ( MarkupContainer parent , String id , IModel < Integer > rating , int nrOfStars , IModel < Integer > nrOfVotes , boolean addDefaultCssStyle ) { } public RatingPanel ( MarkupContainer parent , String id , int nrOfStars ) { } public final void addDefaultCssStyle ( ) { } public RatingPanel setRatingLabelVisible ( boolean visible ) { } protected String getActiveStarUrl ( int iteration ) { } protected String getInactiveStarUrl ( int iteration ) { } protected Component newRatingLabel ( MarkupContainer parent , String id , IModel < Integer > rating , IModel < Integer > nrOfVotes ) { } protected Component newRatingStarBar ( MarkupContainer parent , String id , IModel < Integer > nrOfStars ) { } protected abstract boolean onIsStarActive ( int star ) { } protected abstract void onRated ( int rating , AjaxRequestTarget target ) { } }

Fix:
return ! ( ( ( Boolean ) ( hasVoted . getObject ( ) ) ) . booleanValue ( ) ) ;
Buggy code:
public class CheckRenderer extends JPanel implements TreeCellRenderer { private JCheckBox check ; private CheckRenderer . TreeLabel label ; public CheckRenderer ( ) { } public Component getTreeCellRendererComponent ( JTree tree , Object value , boolean isSelected , boolean expanded , boolean leaf , int row , boolean hasFocus ) { CheckableItem item = ( ( CheckableItem ) ( value ) ) ; check . setSelected ( item . isSelected ( ) ) ; label . setFont ( tree . getFont ( ) ) ; <START_BUG> label . setText ( item . getName ( ) ) ; <END_BUG> label . setSelected ( isSelected ) ; label . setFocus ( hasFocus ) ; label . setIcon ( item . getIcon ( ) ) ; check . setSelected ( item . isSelected ( ) ) ; return this ; } public Dimension getPreferredSize ( ) { } public void doLayout ( ) { } public void setBackground ( Color color ) { } public class TreeLabel extends JLabel { boolean isSelected ; boolean hasFocus ; public TreeLabel ( ) { } public void setBackground ( Color color ) { } public void paint ( Graphics g ) { } public Dimension getPreferredSize ( ) { } public void setSelected ( boolean isSelected ) { } public void setFocus ( boolean hasFocus ) { } } }

Fix:
label . setText ( item . toString ( ) ) ;
Buggy code:
public class QRStringInterpreter { private String [ ] qrStrings ; private static String examID ; private static String studentID ; private static String questionNum ; private static String answerNum ; private static String versionNum ; private static int x = 0 ; private static ArrayList < Response > responses = new ArrayList < Response > ( ) ; private static ArrayList < ResultPoint [ ] > points ; public void interpret ( File examFile ) throws Exception { } public ArrayList < Response > getResponses ( ) { } public static void main ( String [ ] args ) throws Exception { QRStringInterpreter i = new QRStringInterpreter ( ) ; File exam = new File ( "exam.pdf" ) ; i . interpret ( exam ) ; for ( int j = 0 ; j < ( QRStringInterpreter . responses . size ( ) ) ; j ++ ) { System . out . println ( ( ( ( "Response<seq2seq4repair_space>" + j ) + "'s<seq2seq4repair_space>version<seq2seq4repair_space>number:<seq2seq4repair_space>" ) + ( QRStringInterpreter . responses . get ( j ) . getVersionNum ( ) ) ) ) ; System . out . println ( ( ( ( "Response<seq2seq4repair_space>" + j ) + "'s<seq2seq4repair_space>exam<seq2seq4repair_space>id:<seq2seq4repair_space>" ) + ( QRStringInterpreter . responses . get ( j ) . getExamID ( ) ) ) ) ; System . out . println ( ( ( ( "Response<seq2seq4repair_space>" + j ) + "'s<seq2seq4repair_space>student<seq2seq4repair_space>Id:<seq2seq4repair_space>" ) + ( QRStringInterpreter . responses . get ( j ) . getStudentID ( ) ) ) ) ; System . out . println ( ( ( ( "Response<seq2seq4repair_space>" + j ) + "'s<seq2seq4repair_space>question<seq2seq4repair_space>num:<seq2seq4repair_space>" ) + ( QRStringInterpreter . responses . get ( j ) . getQuestionNum ( ) ) ) ) ; <START_BUG> System . out . println ( ( ( ( "Response<seq2seq4repair_space>" + j ) + "'s<seq2seq4repair_space>answer<seq2seq4repair_space>num:<seq2seq4repair_space>" ) + ( QRStringInterpreter . responses . get ( j ) . getAnswerNum ( ) ) ) ) ; <END_BUG> System . out . println ( ( ( ( "Response<seq2seq4repair_space>" + j ) + "'s<seq2seq4repair_space>page<seq2seq4repair_space>number:<seq2seq4repair_space>" ) + ( QRStringInterpreter . responses . get ( j ) . getPageNum ( ) ) ) ) ; System . out . println ( ( ( "Response<seq2seq4repair_space>" + j ) + "'s<seq2seq4repair_space>coordinates:" ) ) ; ResultPoint [ ] coordinates = QRStringInterpreter . responses . get ( j ) . getCoordinates ( ) ; for ( int k = 0 ; k < ( coordinates . length ) ; k ++ ) { System . out . println ( coordinates [ k ] ) ; } System . out . println ( ) ; } } }

Fix:
System . out . println ( ( ( ( "Response<seq2seq4repair_space>" + j ) + "'s<seq2seq4repair_space>answer<seq2seq4repair_space>num:<seq2seq4repair_space>" ) + ( QRStringInterpreter . responses . get ( j ) . getResponseNum ( ) ) ) ) ;
Buggy code:
public class TypeValidator extends StringValidator { private Locale locale = null ; private Class type ; public TypeValidator ( final Class type ) { } public TypeValidator ( final Class type , final Locale locale ) { } public final Class getType ( ) { } public void onValidate ( String value ) { } public String toString ( ) { } protected Map messageModel ( final ConversionException e ) { final Map model = super . messageModel ( ) ; model . put ( "type" , type ) ; final Locale locale = e . getLocale ( ) ; if ( locale != null ) { model . put ( "locale" , locale ) ; } <START_BUG> model . put ( "exception" , e . getMessage ( ) ) ; <END_BUG> Format format = e . getFormat ( ) ; if ( format instanceof SimpleDateFormat ) { model . put ( "format" , ( ( SimpleDateFormat ) ( format ) ) . toLocalizedPattern ( ) ) ; } return model ; } private final Locale getLocale ( ) { } }

Fix:
model . put ( "exception" , e ) ;
Buggy code:
public class GrocerySQLiteHelper extends SQLiteOpenHelper { private static final String TAG_GROCERY_DB = "groceryDB" ; private static final int DATABASE_VERSION = 1 ; private static final String DATABASE_NAME = "GroceriesDB" ; private static final String TABLE_GROCERIES = "groceries" ; private static final String KEY_ID = "id" ; private static final String KEY_NAME = "name" ; private static final String KEY_QUANTITY = "quantity" ; private static final String KEY_EXPIRATION_DATE = "expirationDate" ; private static final String [ ] COLUMNS = new String [ ] { GrocerySQLiteHelper . KEY_ID , GrocerySQLiteHelper . KEY_NAME , GrocerySQLiteHelper . KEY_QUANTITY } ; public GrocerySQLiteHelper ( Context context ) { } @ Override public void onCreate ( SQLiteDatabase db ) { } @ Override public void onUpgrade ( SQLiteDatabase db , int oldVersion , int newVersion ) { } public long addGroceryToDatabase ( Grocery grocery ) { long idToReturn = 0 ; Log . d ( "addGroceryToDatabase" , grocery . toString ( ) ) ; SQLiteDatabase db = this . getWritableDatabase ( ) ; ContentValues values = new ContentValues ( ) ; values . put ( GrocerySQLiteHelper . KEY_NAME , grocery . getName ( ) ) ; values . put ( GrocerySQLiteHelper . KEY_QUANTITY , grocery . getQuantity ( ) ) ; values . put ( GrocerySQLiteHelper . KEY_EXPIRATION_DATE , grocery . dateAsString ( ) ) ; idToReturn = db . insert ( GrocerySQLiteHelper . TABLE_GROCERIES , null , values ) ; db . close ( ) ; <START_BUG> return idToReturn ; <END_BUG> } public void checkItemIfExists ( ) { } public Grocery getGroceryByID ( int id ) { } public Grocery getGroceryByName ( String name ) { } public Set < Grocery > getAllGroceries ( ) { } public int updateGroceryItem ( Grocery grocery ) { } public void deleteItemFromDB ( Grocery grocery ) { } public boolean expiringItems ( ) { } public void updateGroceryDB ( Grocery grocery ) { } }

Fix:
return idToReturn + 1 ;
Buggy code:
public class UnknownElement extends Task { private String elementName ; private String namespace ; private String qname ; private Object realThing ; private List children = null ; private boolean presetDefed = false ; public UnknownElement ( String elementName ) { } public List getChildren ( ) { } public String getTag ( ) { } public String getNamespace ( ) { } public void setNamespace ( String namespace ) { } public String getQName ( ) { } public void setQName ( String qname ) { } public RuntimeConfigurable getWrapper ( ) { } public void maybeConfigure ( ) throws BuildException { } public void configure ( Object realObject ) { } protected void handleOutput ( String output ) { } protected int handleInput ( byte [ ] buffer , int offset , int length ) throws IOException { } protected void handleFlush ( String output ) { } protected void handleErrorOutput ( String output ) { } protected void handleErrorFlush ( String output ) { } public void execute ( ) { } public void addChild ( UnknownElement child ) { } protected void handleChildren ( Object parent , RuntimeConfigurable parentWrapper ) throws BuildException { if ( parent instanceof TypeAdapter ) { parent = ( ( TypeAdapter ) ( parent ) ) . getProxy ( ) ; } String parentUri = getNamespace ( ) ; Class parentClass = parent . getClass ( ) ; <START_BUG> IntrospectionHelper ih = IntrospectionHelper . getHelper ( parentClass ) ; <END_BUG> if ( ( children ) != null ) { Iterator it = children . iterator ( ) ; for ( int i = 0 ; it . hasNext ( ) ; i ++ ) { RuntimeConfigurable childWrapper = parentWrapper . getChild ( i ) ; UnknownElement child = ( ( UnknownElement ) ( it . next ( ) ) ) ; try { if ( ! ( handleChild ( parentUri , ih , parent , child , childWrapper ) ) ) { if ( ! ( parent instanceof TaskContainer ) ) { ih . throwNotSupported ( getProject ( ) , parent , child . getTag ( ) ) ; } else { TaskContainer container = ( ( TaskContainer ) ( parent ) ) ; container . addTask ( child ) ; } } } catch ( UnsupportedElementException ex ) { throw new BuildException ( ( ( ( ( parentWrapper . getElementTag ( ) ) + "<seq2seq4repair_space>doesn\'t<seq2seq4repair_space>support<seq2seq4repair_space>the<seq2seq4repair_space>nested<seq2seq4repair_space>\"" ) + ( ex . getElement ( ) ) ) + "\"<seq2seq4repair_space>element." ) , ex ) ; } } } } protected String getComponentName ( ) { } public void applyPreSet ( UnknownElement u ) { } protected Object makeObject ( UnknownElement ue , RuntimeConfigurable w ) { } protected Task makeTask ( UnknownElement ue , RuntimeConfigurable w ) { } protected BuildException getNotFoundException ( String what , String name ) { } public String getTaskName ( ) { } public Task getTask ( ) { } public Object getRealThing ( ) { } public void setRealThing ( Object realThing ) { } private boolean handleChild ( String parentUri , IntrospectionHelper ih , Object parent , UnknownElement child , RuntimeConfigurable childWrapper ) { } public boolean similar ( Object obj ) { } private static boolean equalsString ( String a , String b ) { } }

Fix:
IntrospectionHelper ih = IntrospectionHelper . getHelper ( getProject ( ) , parentClass ) ;
Buggy code:
public abstract class ForestFireModelValidationTest { private static GraphStructure deduplicateNewUndirectedEdges ( GraphStructure result , long maximumOriginalId ) { Map < Long , Set < Long > > edges = new HashMap < > ( ) ; for ( long vertexId : result . getVertices ( ) ) { edges . put ( vertexId , new java . util . HashSet ( result . getEdgesForVertex ( vertexId ) ) ) ; } for ( long sourceId : result . getVertices ( ) ) { if ( sourceId > maximumOriginalId ) { for ( long destinationId : result . getEdgesForVertex ( sourceId ) ) { if ( destinationId < sourceId ) { <START_BUG> assertThat ( ( ( ( ( "edge<seq2seq4repair_space>from<seq2seq4repair_space>" + sourceId ) + "<seq2seq4repair_space>to<seq2seq4repair_space>" ) + destinationId ) + "<seq2seq4repair_space>is<seq2seq4repair_space>undirected" ) , edges . get ( destinationId ) , contains ( sourceId ) ) ; <END_BUG> edges . get ( destinationId ) . remove ( sourceId ) ; } } } } return new GraphStructure ( edges ) ; } private static void verifyOriginalGraphUnchanged ( GraphStructure original , GraphStructure result ) { } private static void verifyNewVerticesCreated ( GraphStructure original , GraphStructure result , long maximumOriginalId , int numberOfNewVertices ) { } private static void verifyNewEdgesAreFeasible ( GraphStructure original , GraphStructure result , long newVertexId , int numberOfIterations ) { } private static boolean maxDistanceWithinLimit ( Map < Long , Set < Long > > edges , long sourceVertex , int maximumDistance ) { } public abstract GraphStructure executeDirectedForestFireModel ( GraphStructure graph , ForestFireModelParameters parameters ) throws Exception { } public abstract GraphStructure executeUndirectedForestFireModel ( GraphStructure graph , ForestFireModelParameters parameters ) throws Exception { } @ Test public final void testDirectedForestFireModelOnValidationGraph ( ) throws Exception { } @ Test public final void testUndirectedForestFireModelOnValidationGraph ( ) throws Exception { } private void validateForestFireModel ( GraphStructure inputGraph , GraphStructure outputGraph , long maximumOriginalId , int numberOfNewVertices , int numberOfIterations , boolean graphIsDirected ) { } }

Fix:
assertThat ( ( ( ( ( "edge<seq2seq4repair_space>from<seq2seq4repair_space>" + sourceId ) + "<seq2seq4repair_space>to<seq2seq4repair_space>" ) + destinationId ) + "<seq2seq4repair_space>is<seq2seq4repair_space>undirected" ) , sourceId , isIn ( edges . get ( destinationId ) ) ) ;
Buggy code:
public class CaptchaApplication extends WicketExampleApplication { public CaptchaApplication ( ) { } public Class getHomePage ( ) { <START_BUG> return Captcha . class ; <END_BUG> } }

Fix:
return Index . class ;
Buggy code:
public class MainFrame extends JFrame implements Remoteable , TestListener { private static final String LOCAL = "*local*" ; private static final String DEFAULT_TITLE = ( "Apache<seq2seq4repair_space>JMeter<seq2seq4repair_space>(" + ( JMeterUtils . getJMeterVersion ( ) ) ) + ")" ; private JMeterMenuBar menuBar ; private JScrollPane mainPanel ; private JScrollPane treePanel ; private JTree tree ; private ImageIcon runningIcon = JMeterUtils . getImage ( "thread.enabled.gif" ) ; private ImageIcon stoppedIcon = JMeterUtils . getImage ( "thread.disabled.gif" ) ; private JButton runningIndicator ; private int previousDragXLocation = 0 ; private int previousDragYLocation = 0 ; private Set hosts = new HashSet ( ) ; private JDialog stoppingMessage ; private JLabel totalThreads ; private JLabel activeThreads ; public MainFrame ( ActionListener actionHandler , TreeModel treeModel , JMeterTreeListener treeListener ) { } @ Deprecated public MainFrame ( ) { } public void setFileLoadEnabled ( boolean enabled ) { } public void setFileSaveEnabled ( boolean enabled ) { } public void setFileRevertEnabled ( boolean enabled ) { } public void setProjectFileLoaded ( String file ) { } public void setEditMenu ( JPopupMenu menu ) { } public void setEditEnabled ( boolean enabled ) { } public void setEditAddMenu ( JMenu menu ) { } public void setEditAddEnabled ( boolean enabled ) { } public void setEditRemoveEnabled ( boolean enabled ) { } public void closeMenu ( ) { } public void showStoppingMessage ( String host ) { if ( ( stoppingMessage ) != null ) { stoppingMessage . dispose ( ) ; } stoppingMessage = new JDialog ( this , JMeterUtils . getResString ( "stopping_test_title" ) , true ) ; JLabel stopLabel = new JLabel ( ( ( ( JMeterUtils . getResString ( "stopping_test" ) ) + ":<seq2seq4repair_space>" ) + host ) ) ; stopLabel . setBorder ( BorderFactory . createEmptyBorder ( 20 , 20 , 20 , 20 ) ) ; stoppingMessage . getContentPane ( ) . add ( stopLabel ) ; stoppingMessage . pack ( ) ; ComponentUtil . centerComponentInComponent ( this , stoppingMessage ) ; SwingUtilities . invokeLater ( new Runnable ( ) { public void run ( ) { if ( ( stoppingMessage ) != null ) { <START_BUG> stoppingMessage . show ( ) ; <END_BUG> } } } ) ; } public void updateCounts ( ) { } public void setMainPanel ( JComponent comp ) { } public JTree getTree ( ) { } public void testStarted ( ) { } public void testStarted ( String host ) { } public void testEnded ( ) { } public void testEnded ( String host ) { } public void testIterationStart ( LoopIterationEvent event ) { } private void init ( ) { } public void setExtendedFrameTitle ( String fname ) { } private Component createToolBar ( ) { } private JScrollPane createTreePanel ( ) { } private JScrollPane createMainPanel ( ) { } private JTree makeTree ( TreeModel treeModel , JMeterTreeListener treeListener ) { } private TreeCellRenderer getCellRenderer ( ) { } public void drawDraggedComponent ( Component dragIcon , int x , int y ) { } private static class WindowHappenings extends WindowAdapter { @ Override public void windowClosing ( WindowEvent event ) { } } }

Fix:
stoppingMessage . setVisible ( true ) ;
Buggy code:
public class Neo4JToDotParser { private GraphDatabaseService db ; OutputStream out = null ; public Neo4JToDotParser ( GraphDatabaseService db ) { } public Response parseNeo4J ( String tradId ) { String filename = "upload//" + "output.dot" ; Node startNode = DatabaseService . getStartNode ( tradId , db ) ; ExecutionEngine engine = new ExecutionEngine ( db ) ; try ( Transaction tx = db . beginTx ( ) ) { if ( startNode == null ) return Response . status ( NOT_FOUND ) . build ( ) ; File file = new File ( filename ) ; file . createNewFile ( ) ; out = new FileOutputStream ( file ) ; write ( "digraph<seq2seq4repair_space>{<seq2seq4repair_space>" ) ; long edgeId = 0 ; String subgraph = "" ; for ( Node node : db . traversalDescription ( ) . breadthFirst ( ) . relationships ( NORMAL , OUTGOING ) . uniqueness ( NODE_GLOBAL ) . traverse ( startNode ) . nodes ( ) ) { write ( ( ( ( ( "n" + ( node . getId ( ) ) ) + "<seq2seq4repair_space>[label=\"" ) + ( node . getProperty ( "dn15" ) . toString ( ) ) ) + "\"];" ) ) ; for ( Relationship rel : node . getRelationships ( OUTGOING , NORMAL ) ) { if ( ( rel != null ) && ( rel . hasProperty ( "lexemes" ) ) ) { String [ ] lexemes = ( ( String [ ] ) ( rel . getProperty ( "lexemes" ) ) ) ; String lex_str = "" ; Iterator < String > it = Arrays . asList ( lexemes ) . iterator ( ) ; while ( it . hasNext ( ) ) { lex_str += ( "" + ( it . next ( ) ) ) + "" ; if ( it . hasNext ( ) ) lex_str += "," ; } write ( ( ( ( ( ( ( ( ( ( "n" + ( rel . getStartNode ( ) . getId ( ) ) ) + "->" ) + "n" ) + ( rel . getEndNode ( ) . getId ( ) ) ) + "[label=\"" ) + lex_str ) + "\";id=\"e" ) + ( edgeId ++ ) ) + "\"];" ) ) ; } } for ( Relationship rel : node . getRelationships ( OUTGOING , RELATIONSHIP ) ) { subgraph += ( ( ( ( ( ( ( ( "n" + ( rel . getStartNode ( ) . getId ( ) ) ) + "->" ) + "n" ) + ( rel . getEndNode ( ) . getId ( ) ) ) + "[style=dotted;label=\"" ) + ( rel . getProperty ( "de11" ) . toString ( ) ) ) + "\";id=\"e" ) + ( edgeId ++ ) ) + "\"];" ; } } write ( "subgraph<seq2seq4repair_space>{<seq2seq4repair_space>edge<seq2seq4repair_space>[dir=none]" ) ; write ( subgraph ) ; write ( "<seq2seq4repair_space>}<seq2seq4repair_space>}" ) ; out . flush ( ) ; out . close ( ) ; tx . success ( ) ; } catch ( IOException e ) { e . printStackTrace ( ) ; return Response . status ( INTERNAL_SERVER_ERROR ) . entity ( "Could<seq2seq4repair_space>not<seq2seq4repair_space>write<seq2seq4repair_space>file<seq2seq4repair_space>for<seq2seq4repair_space>export" ) . build ( ) ; } db . shutdown ( ) ; <START_BUG> return null ; <END_BUG> } public Response parseNeo4JStemma ( String tradId , String stemmaTitle ) { } private void write ( String str ) throws IOException { } No newline ; at end ; of file ; }

Fix:
return Response . ok ( ) . build ( ) ;
Buggy code:
public class ConfigurationWizardDialog extends WizardDialog { ConfigurationWizardSelectionWizard wizard = null ; public ConfigurationWizardDialog ( Shell shell , IWorkbench workbench , IStructuredSelection selection ) { } public ConfigurationWizardDialog ( Shell shell , IWorkbench workbench ) { } public ContainerConfigurationResult getResult ( ) { <START_BUG> return wizard . getResult ( ) ; <END_BUG> } }

Fix:
return wizard . getContainerConfigurationResult ( ) ;
Buggy code:
public class Condition { private Condition . Type type ; private Object [ ] vars ; private ArrayList < Object > results ; public Condition ( ) { } public Condition ( Condition . Type type ) { } public Condition ( Condition . Type type , Object ... variables ) { } public boolean consider ( Actor actor , GameWorld world ) { } private boolean range ( Actor actor , GameWorld world ) { } private boolean composite ( Actor actor , GameWorld world , boolean or ) { for ( int i = 0 ; i < ( vars . length ) ; i ++ ) { boolean res = ( ( Condition ) ( vars [ i ] ) ) . consider ( actor , world ) ; if ( or && res ) return true ; if ( ( ! or ) && ( ! res ) ) return false ; } <START_BUG> return false ; <END_BUG> } public static enum Type { ALWAYS , RANDOM , RANGE , OR , AND ; } public static enum ActorClass { ANY , FRIEND , ENEMY ; } }

Fix:
return ! or ;
Buggy code:
public class DB_Schema { public static final String copyrightNotice = Copyright . SHORT_2004 ; public static void doSchemas ( Connection conn , boolean tablesOnly ) throws SQLException { Statement stmt = conn . createStatement ( ) ; ResultSet rs = stmt . executeQuery ( ( "SELECT<seq2seq4repair_space>SCHEMANAME,<seq2seq4repair_space>SCHEMAID<seq2seq4repair_space>" + "FROM<seq2seq4repair_space>SYS.SYSSCHEMAS" ) ) ; boolean firstTime = true ; while ( rs . next ( ) ) { String sName = dblook . addQuotes ( dblook . expandDoubleQuotes ( rs . getString ( 1 ) ) ) ; if ( tablesOnly || ( dblook . isIgnorableSchema ( sName ) ) ) continue ; if ( sName . equals ( "\"APP\"" ) ) continue ; if ( firstTime ) { Logs . reportString ( "----------------------------------------------" ) ; <START_BUG> Logs . reportMessage ( "CSLOOK_Header" , "schemas" ) ; <END_BUG> Logs . reportString ( "----------------------------------------------\n" ) ; } Logs . writeToNewDDL ( ( "CREATE<seq2seq4repair_space>SCHEMA<seq2seq4repair_space>" + sName ) ) ; Logs . writeStmtEndToNewDDL ( ) ; Logs . writeNewlineToNewDDL ( ) ; firstTime = false ; } rs . close ( ) ; stmt . close ( ) ; } }

Fix:
Logs . reportMessage ( "CSLOOK_SchemasHeader" ) ;
Buggy code:
public class CommandlineJavaTest extends TestCase { private String cloneVm ; public CommandlineJavaTest ( String name ) { } private Project project ; public void setUp ( ) { project = new Project ( ) ; <START_BUG> project . setBasedir ( "." ) ; <END_BUG> project . setProperty ( "build.sysclasspath" , "ignore" ) ; cloneVm = System . getProperty ( "build.clonevm" ) ; if ( ( cloneVm ) != null ) { System . setProperty ( "build.clonevm" , "false" ) ; } } public void tearDown ( ) { } public void testGetCommandline ( ) throws Exception { } public void testJarOption ( ) throws Exception { } public void testSysproperties ( ) { } public void testAssertions ( ) throws Exception { } }

Fix:
project . setBasedir ( System . getProperty ( "root" ) ) ;
Buggy code:
public class PropertyModel < T > extends AbstractPropertyModel < T > { private static final long serialVersionUID = 1L ; private final String expression ; public PropertyModel ( final Object modelObject , final String expression ) { } @ Override public String toString ( ) { <START_BUG> StringBuffer sb = new StringBuffer ( super . toString ( ) ) ; <END_BUG> sb . append ( ":expression=[" ) . append ( expression ) . append ( "]" ) ; return sb . toString ( ) ; } @ Override protected String propertyExpression ( ) { } }

Fix:
StringBuilder sb = new StringBuilder ( super . toString ( ) ) ;
Buggy code:
@ RunWith ( Arquillian . class ) @ RunAsClient public class SingletonTestCase extends ClusterAbstractTestCase { @ Deployment ( name = DEPLOYMENT_1 , managed = false , testable = false ) @ TargetsContainer ( CONTAINER_1 ) public static Archive < ? > deployment0 ( ) { } @ Deployment ( name = DEPLOYMENT_2 , managed = false , testable = false ) @ TargetsContainer ( CONTAINER_2 ) public static Archive < ? > deployment1 ( ) { } private static Archive < ? > createDeployment ( ) { WebArchive war = ShrinkWrap . create ( WebArchive . class , "singleton.war" ) ; war . addPackage ( MyService . class . getPackage ( ) ) ; <START_BUG> war . setManifest ( new StringAsset ( "Manifest-Version:<seq2seq4repair_space>1.0\nDependencies:<seq2seq4repair_space>org.wildfly.clustering.singleton,<seq2seq4repair_space>org.jboss.as.server\n" ) ) ; <END_BUG> war . addAsServiceProvider ( ServiceActivator . class , MyServiceActivator . class ) ; return war ; } @ Test public void testSingletonService ( @ ArquillianResource @ OperateOnDeployment ( DEPLOYMENT_1 ) URL baseURL1 , @ ArquillianResource @ OperateOnDeployment ( DEPLOYMENT_2 ) URL baseURL2 ) throws IOException , URISyntaxException { } }

Fix:
war . setManifest ( new StringAsset ( "Manifest-Version:<seq2seq4repair_space>1.0\nDependencies:<seq2seq4repair_space>org.jboss.as.server\n" ) ) ;
Buggy code:
public class ServerProcessReloadHandler extends ProcessReloadHandler < RunningModeControl > { private static final AttributeDefinition USE_CURRENT_SERVER_CONFIG = new org . jboss . as . controller . SimpleAttributeDefinitionBuilder ( ModelDescriptionConstants . USE_CURRENT_SERVER_CONFIG , ModelType . BOOLEAN , true ) . setDefaultValue ( new ModelNode ( true ) ) . build ( ) ; private static final AttributeDefinition [ ] ATTRIBUTES = new AttributeDefinition [ ] { ADMIN_ONLY , ServerProcessReloadHandler . USE_CURRENT_SERVER_CONFIG } ; public static final OperationDefinition DEFINITION = new org . jboss . as . controller . SimpleOperationDefinitionBuilder ( OPERATION_NAME , ServerDescriptions . getResourceDescriptionResolver ( "server" ) ) . setParameters ( ServerProcessReloadHandler . ATTRIBUTES ) . build ( ) ; public ServerProcessReloadHandler ( ServiceName rootService , RunningModeControl runningModeControl , ControlledProcessState processState ) { } @ Override protected ProcessReloadHandler . ReloadContext < RunningModeControl > initializeReloadContext ( final OperationContext context , final ModelNode operation ) throws OperationFailedException { final boolean adminOnly = ADMIN_ONLY . resolveModelAttribute ( context , operation ) . asBoolean ( false ) ; final boolean useCurrentConfig = ServerProcessReloadHandler . USE_CURRENT_SERVER_CONFIG . resolveModelAttribute ( context , operation ) . asBoolean ( true ) ; return new ReloadContext < RunningModeControl > ( ) { @ Override public void reloadInitiated ( RunningModeControl runningModeControl ) { } @ Override public void doReload ( RunningModeControl runningModeControl ) { runningModeControl . setRunningMode ( ( adminOnly ? RunningMode . ADMIN_ONLY : RunningMode . NORMAL ) ) ; <START_BUG> runningModeControl . setReloaded ( true ) ; <END_BUG> runningModeControl . setUseCurrentConfig ( useCurrentConfig ) ; } } ; } }

Fix:
runningModeControl . setReloaded ( ) ;
Buggy code:
public class J2EEServer extends J2EEManagedObject implements J2EEServerMBean { private List mApplications = new ArrayList ( ) ; private List mResources = new ArrayList ( ) ; private List mNodes = new ArrayList ( ) ; private List mJVMs = new ArrayList ( ) ; private String mJ2eeVendor = null ; public J2EEServer ( String pName , ObjectName pDomain , String pJ2eeVendor ) throws MalformedObjectNameException , InvalidParentException { } public J2EEServer ( String pName , ObjectName pDomain , ObjectName [ ] pApplications , ObjectName [ ] pResources , ObjectName [ ] pNodes , ObjectName [ ] pJVMs , String pJ2eeVendor ) throws MalformedObjectNameException , InvalidParentException { } public ObjectName [ ] getApplications ( ) { } public ObjectName getApplication ( int pIndex ) { } public ObjectName [ ] getNodes ( ) { } public ObjectName getNode ( int pIndex ) { } public ObjectName [ ] getResources ( ) { } public ObjectName getResource ( int pIndex ) { } public ObjectName [ ] getJavaVMs ( ) { } public ObjectName getJavaVM ( int pIndex ) { } public String getJ2eeVendor ( ) { } public void addChild ( ObjectName pChild ) { Hashtable lProperties = pChild . getKeyPropertyList ( ) ; String lType = ( lProperties . get ( "type" ) ) + "" ; <START_BUG> if ( "Application" . equals ( lType ) ) { <END_BUG> mApplications . add ( pChild ) ; } else if ( "Node" . equals ( lType ) ) { mNodes . add ( pChild ) ; } else if ( "JVM" . equals ( lType ) ) { mJVMs . add ( pChild ) ; } else if ( "Resource" . equals ( lType ) ) { mResources . add ( pChild ) ; } } public void removeChild ( ObjectName pChild ) { } public String toString ( ) { } }

Fix:
if ( "J2EEApplication" . equals ( lType ) ) {
Buggy code:
public class FieldInfo extends ClassFileStruct implements Comparable , AttributeNamesConstants , IBinaryField , TypeIds { private int accessFlags ; private int attributeBytes ; private Constant constant ; private int [ ] constantPoolOffsets ; private char [ ] descriptor ; private char [ ] name ; private char [ ] signature ; private int signatureUtf8Offset ; private long tagBits ; private Object wrappedConstantValue ; public FieldInfo ( byte [ ] classFileBytes , int [ ] offsets , int offset ) { } public int compareTo ( Object o ) { } private int decodeAnnotation ( int offset ) { } private int decodeElementValue ( int offset ) { int readOffset = offset ; int tag = u1At ( readOffset ) ; readOffset ++ ; switch ( tag ) { case 'B' : case 'C' : case 'D' : case 'F' : case 'I' : case 'J' : case 'S' : case 'Z' : case 's' : readOffset += 2 ; break ; case 'e' : readOffset += 4 ; break ; case 'c' : readOffset += 2 ; break ; case '@' : <START_BUG> readOffset += decodeAnnotation ( readOffset ) ; <END_BUG> break ; case '[' : int numberOfValues = u2At ( readOffset ) ; readOffset += 2 ; for ( int i = 0 ; i < numberOfValues ; i ++ ) { readOffset = decodeElementValue ( readOffset ) ; } break ; } return readOffset ; } private void decodeStandardAnnotations ( int offset ) { } public Constant getConstant ( ) { } public char [ ] getGenericSignature ( ) { } public int getModifiers ( ) { } public char [ ] getName ( ) { } public long getTagBits ( ) { } public char [ ] getTypeName ( ) { } public Object getWrappedConstantValue ( ) { } public boolean hasConstant ( ) { } void initialize ( ) { } public boolean isSynthetic ( ) { } private void readConstantAttribute ( ) { } private void readModifierRelatedAttributes ( ) { } protected void reset ( ) { } public int sizeInBytes ( ) { } public void throwFormatException ( ) throws ClassFormatException { } public String toString ( ) { } }

Fix:
readOffset = decodeAnnotation ( readOffset ) ;
Buggy code:
public class JSONBuilder { private static final String KEY_FUNCTION = "function" ; private static final String KEY_VALUE = "value" ; public static JSONObject createJSONFromParam ( String functionName , Object value ) { } public static JSONObject createJSONFromObject ( Object object ) { JSONObject objectAsJsonObject = null ; if ( object != null ) { try { <START_BUG> Gson gsonHandler = new GsonBuilder ( ) . setDateFormat ( "yyyy-MM-dd<seq2seq4repair_space>HH:mm:ss" ) . create ( ) ; <END_BUG> String objectAsJsonString = gsonHandler . toJson ( object ) ; objectAsJsonObject = new JSONObject ( objectAsJsonString ) ; } catch ( JSONException e ) { e . printStackTrace ( ) ; } } return objectAsJsonObject ; } }

Fix:
Gson gsonHandler = new GsonBuilder ( ) . setDateFormat ( "yyyy-MM-dd<seq2seq4repair_space>HH:mm:ss" ) . serializeNulls ( ) . create ( ) ;
Buggy code:
public class CSVParserTest { String code = "a,b,c,d\n" + ( ( "<seq2seq4repair_space>a<seq2seq4repair_space>,<seq2seq4repair_space>b<seq2seq4repair_space>,<seq2seq4repair_space>1<seq2seq4repair_space>2<seq2seq4repair_space>\n" + "\"foo<seq2seq4repair_space>baar\",<seq2seq4repair_space>b,\n" ) + "<seq2seq4repair_space>\"foo\n,,\n\"\",,\n\"\"\",d,e\n" ) ; String [ ] [ ] res = new String [ ] [ ] { new String [ ] { "a" , "b" , "c" , "d" } , new String [ ] { "a" , "b" , "1<seq2seq4repair_space>2" } , new String [ ] { "foo<seq2seq4repair_space>baar" , "b" , "" } , new String [ ] { "foo\n,,\n\",,\n\"" , "d" , "e" } } ; @ Test public void testGetLine ( ) throws IOException { CSVParser parser = new CSVParser ( new StringReader ( code ) ) ; for ( String [ ] re : res ) { assertTrue ( Arrays . equals ( re , parser . getRecord ( ) . values ( ) ) ) ; } <START_BUG> assertTrue ( ( ( parser . getRecord ( ) ) == null ) ) ; <END_BUG> } @ Test public void testGetRecords ( ) throws IOException { } @ Test public void testExcelFormat1 ( ) throws IOException { } @ Test public void testExcelFormat2 ( ) throws Exception { } @ Test public void testEndOfFileBehaviourExcel ( ) throws Exception { } @ Test public void testEndOfFileBehaviorCSV ( ) throws Exception { } @ Test public void testEmptyLineBehaviourExcel ( ) throws Exception { } @ Test public void testEmptyLineBehaviourCSV ( ) throws Exception { } @ Test @ Ignore public void testBackslashEscapingOld ( ) throws IOException { } @ Test public void testBackslashEscaping ( ) throws IOException { } @ Test public void testBackslashEscaping2 ( ) throws IOException { } @ Test public void testDefaultFormat ( ) throws IOException { } @ Test public void testCarriageReturnLineFeedEndings ( ) throws IOException { } @ Test public void testCarriageReturnEndings ( ) throws IOException { } @ Test public void testLineFeedEndings ( ) throws IOException { } @ Test public void testIgnoreEmptyLines ( ) throws IOException { } @ Test public void testForEach ( ) throws Exception { } @ Test public void testIterator ( ) throws Exception { } @ Test public void testHeader ( ) throws Exception { } @ Test public void testProvidedHeader ( ) throws Exception { } }

Fix:
assertNull ( parser . getRecord ( ) ) ;
Buggy code:
public class ExclamationTopology { public static class ExclamationBolt extends BaseRichBolt { OutputCollector _collector ; @ Override public void prepare ( Map conf , TopologyContext context , OutputCollector collector ) { } @ Override public void execute ( Tuple tuple ) { } @ Override public void declareOutputFields ( OutputFieldsDeclarer declarer ) { } } public static void main ( String [ ] args ) throws Exception { TopologyBuilder builder = new TopologyBuilder ( ) ; builder . setSpout ( "word" , new TestWordSpout ( ) , 10 ) ; builder . setBolt ( "exclaim1" , new ExclamationTopology . ExclamationBolt ( ) , 3 ) . shuffleGrouping ( "word" ) ; builder . setBolt ( "exclaim2" , new ExclamationTopology . ExclamationBolt ( ) , 2 ) . shuffleGrouping ( "exclaim1" ) ; Config conf = new Config ( ) ; conf . setDebug ( true ) ; if ( ( args != null ) && ( ( args . length ) > 0 ) ) { conf . setNumWorkers ( 3 ) ; <START_BUG> StormSubmitter . submitTopologyWithProgressBar ( args [ 0 ] , conf , builder . createTopology ( ) ) ; <END_BUG> } else { LocalCluster cluster = new LocalCluster ( ) ; cluster . submitTopology ( "test" , conf , builder . createTopology ( ) ) ; Utils . sleep ( 10000 ) ; cluster . killTopology ( "test" ) ; cluster . shutdown ( ) ; } } }

Fix:
StormSubmitter . submitTopology ( args [ 0 ] , conf , builder . createTopology ( ) ) ;
Buggy code:
public class JacORBExtension implements Extension { private static final JacORBSubsystemParser PARSER = JacORBSubsystemParser . INSTANCE ; public static final String SUBSYSTEM_NAME = "jacorb" ; private static final String RESOURCE_NAME = ( JacORBExtension . class . getPackage ( ) . getName ( ) ) + ".LocalDescriptions" ; static ResourceDescriptionResolver getResourceDescriptionResolver ( final String keyPrefix ) { } @ Override public void initialize ( ExtensionContext context ) { <START_BUG> final SubsystemRegistration subsystem = context . registerSubsystem ( JacORBExtension . SUBSYSTEM_NAME , 1 , 1 ) ; <END_BUG> final ManagementResourceRegistration subsystemRegistration = subsystem . registerSubsystemModel ( INSTANCE ) ; subsystemRegistration . registerOperationHandler ( DESCRIBE , GenericSubsystemDescribeHandler . INSTANCE , GenericSubsystemDescribeHandler . INSTANCE , false , PRIVATE ) ; subsystem . registerXMLElementWriter ( JacORBExtension . PARSER ) ; } @ Override public void initializeParsers ( ExtensionParsingContext context ) { } }

Fix:
final SubsystemRegistration subsystem = context . registerSubsystem ( JacORBExtension . SUBSYSTEM_NAME , 1 , 0 ) ;
Buggy code:
public class QualifiedTypeReference extends TypeReference { public char [ ] [ ] tokens ; public long [ ] sourcePositions ; public QualifiedTypeReference ( char [ ] [ ] sources , long [ ] poss ) { } public TypeReference copyDims ( int dim ) { } protected TypeBinding findNextTypeBinding ( int tokenIndex , Scope scope , PackageBinding packageBinding ) { } public char [ ] getLastToken ( ) { } protected TypeBinding getTypeBinding ( Scope scope ) { if ( ( this . resolvedType ) != null ) return this . resolvedType ; Binding binding = scope . getPackage ( this . tokens ) ; if ( ( binding != null ) && ( ! ( binding . isValidBinding ( ) ) ) ) return ( ( ReferenceBinding ) ( binding ) ) ; PackageBinding packageBinding = ( binding == null ) ? null : ( ( PackageBinding ) ( binding ) ) ; boolean isClassScope = ( scope . kind ) == ( Scope . CLASS_SCOPE ) ; ReferenceBinding qualifiedType = null ; for ( int i = ( packageBinding == null ) ? 0 : packageBinding . compoundName . length , max = this . tokens . length ; i < max ; i ++ ) { findNextTypeBinding ( i , scope , packageBinding ) ; if ( ! ( this . resolvedType . isValidBinding ( ) ) ) return this . resolvedType ; <START_BUG> if ( ( i == 0 ) && ( this . resolvedType . isTypeVariable ( ) ) ) { <END_BUG> scope . problemReporter ( ) . illegalAccessFromTypeVariable ( ( ( TypeVariableBinding ) ( this . resolvedType ) ) , this ) ; return this . resolvedType = null ; } if ( isClassScope ) if ( ( ( ClassScope ) ( scope ) ) . detectHierarchyCycle ( this . resolvedType , this , null ) ) return null ; ReferenceBinding currentType = ( ( ReferenceBinding ) ( this . resolvedType ) ) ; if ( qualifiedType != null ) { boolean rawQualified ; if ( currentType . isGenericType ( ) ) { qualifiedType = scope . environment ( ) . createRawType ( currentType , qualifiedType ) ; } else if ( ( rawQualified = qualifiedType . isRawType ( ) ) && ( ! ( currentType . isStatic ( ) ) ) ) { qualifiedType = scope . environment ( ) . createRawType ( ( ( ReferenceBinding ) ( currentType . erasure ( ) ) ) , qualifiedType ) ; } else if ( ( rawQualified || ( qualifiedType . isParameterizedType ( ) ) ) && ( ( qualifiedType . erasure ( ) ) == ( currentType . enclosingType ( ) . erasure ( ) ) ) ) { qualifiedType = scope . environment ( ) . createParameterizedType ( ( ( ReferenceBinding ) ( currentType . erasure ( ) ) ) , null , qualifiedType ) ; } else { qualifiedType = currentType ; } } else { qualifiedType = ( currentType . isGenericType ( ) ) ? ( ( ReferenceBinding ) ( scope . environment ( ) . convertToRawType ( currentType ) ) ) : currentType ; } } this . resolvedType = qualifiedType ; return this . resolvedType ; } public char [ ] [ ] getTypeName ( ) { } public StringBuffer printExpression ( int indent , StringBuffer output ) { } public void traverse ( ASTVisitor visitor , BlockScope scope ) { } public void traverse ( ASTVisitor visitor , ClassScope scope ) { } }

Fix:
if ( ( ( i == 0 ) && ( this . resolvedType . isTypeVariable ( ) ) ) && ( ( ( ( TypeVariableBinding ) ( this . resolvedType ) ) . firstBound ) == null ) ) {
Buggy code:
public abstract class ContentTransformingResource extends Resource { private static final int BUFFER_SIZE = 8192 ; private Resource resource ; public ContentTransformingResource ( ) { } public ContentTransformingResource ( ResourceCollection other ) { } public void addConfigured ( ResourceCollection a ) { } public String getName ( ) { } public void setName ( String name ) throws BuildException { } public boolean isExists ( ) { } public void setExists ( boolean exists ) { } public long getLastModified ( ) { } public void setLastModified ( long lastmodified ) throws BuildException { } public boolean isDirectory ( ) { } public void setDirectory ( boolean directory ) throws BuildException { } public long getSize ( ) { } public void setSize ( long size ) throws BuildException { } public int compareTo ( Object other ) { } public int hashCode ( ) { } public InputStream getInputStream ( ) throws IOException { } public OutputStream getOutputStream ( ) throws IOException { } public boolean isFilesystemOnly ( ) { <START_BUG> return getResource ( ) . isFilesystemOnly ( ) ; <END_BUG> } public void setRefid ( Reference r ) { } protected abstract InputStream wrapStream ( InputStream in ) throws IOException { } protected abstract OutputStream wrapStream ( OutputStream out ) throws IOException { } private Resource getResource ( ) { } }

Fix:
return false ;
Buggy code:
public class Main { private static final Logger log = Logger . getLogger ( Main . class . getName ( ) ) ; public static void main ( String [ ] args ) { } private static GastosoRestClient inicializaSistema ( final ConsoleReader console ) throws GastosoSystemRTException , IOException { } private static GastosoRestClient inicializaSistema ( final ConsoleReader console , final URI uri ) throws GastosoSystemRTException , IOException { final GastosoRestClient gastosoRestClient ; try { gastosoRestClient = new GastosoRestClient ( uri ) ; final PrintWriter writer = new PrintWriter ( console . getOutput ( ) ) ; boolean conseguiu = Boolean . parseBoolean ( System . getenv ( "ABD_AUTH_OMNI_EST_LICET" ) ) ; int tentativasSobrando = 3 ; System . out . printf ( "Connecting<seq2seq4repair_space>to<seq2seq4repair_space>Gastoso\'s<seq2seq4repair_space>severs<seq2seq4repair_space>on<seq2seq4repair_space>%s:%d.\n" , uri . getHost ( ) , uri . getPort ( ) ) ; while ( ( ! conseguiu ) && ( tentativasSobrando > 0 ) ) { console . setEchoCharacter ( '*' ) ; String password = console . readLine ( "Senha:" ) ; conseguiu = gastosoRestClient . login ( "" , String . valueOf ( password ) ) ; <START_BUG> if ( conseguiu ) { <END_BUG> if ( ( -- tentativasSobrando ) > 0 ) { writer . println ( "Foi<seq2seq4repair_space>mal.<seq2seq4repair_space>Tá<seq2seq4repair_space>errada.\n" ) ; } else { writer . println ( "Não<seq2seq4repair_space>rolou<seq2seq4repair_space>não." ) ; writer . flush ( ) ; System . exit ( 1 ) ; } } } console . setEchoCharacter ( null ) ; console . setPrompt ( "gastoso>" ) ; Main . printWellcome ( writer ) ; } catch ( GastosoSystemRTException e ) { if ( ( e . getCode ( ) ) == ( SERVIDOR_FORA ) ) { System . out . printf ( "%s:%d<seq2seq4repair_space>is<seq2seq4repair_space>not<seq2seq4repair_space>responding.\n" , uri . getHost ( ) , uri . getPort ( ) ) ; System . out . flush ( ) ; System . exit ( 1 ) ; } throw e ; } catch ( GastosoResponseException e ) { throw new GastosoSystemRTException ( e ) ; } return gastosoRestClient ; } private static void restoreCommandHistory ( final ConsoleReader console ) throws IOException { } private static void restoreCommandHistory ( final ConsoleReader console , final File gastosoDir ) throws IOException { } private static void printWellcome ( PrintWriter writer ) { } No newline ; at end ; of file ; }

Fix:
if ( ! conseguiu ) {