nus-yam/ex-repair huggingface dataset:
Buggy code:
public class XmlMessage { private static Logger LOG = Logger . getLogger ( XmlMessage . class ) ; private static final String ROOT_ELEMENT = "XmlMessage" ; private static final String ID_USER = "IdUser" ; private static final String ELSE_PREFERENCE = "preference" ; private static final String ID = "id" ; private static final String NAME = "name" ; private static final String MESSAGE = "message" ; private static final String DIALOG_ID = "dialogID" ; private static final String LIST_USER = "list_user" ; protected static DocumentBuilder builder ; protected static void paramLangXML ( ) { } private static void writeChild ( Element RootElement , Document doc , String strTeg , String str ) { } public static void writeXMLinStream ( XmlSet xmlSet , OutputStream out ) throws TransformerException { } private static String readChild ( Document document , String strTeg ) { } public static XmlSet readXmlFromStream ( InputStream in ) throws IOException , SAXException { XmlSet xmlSet = new XmlSet ( ( - 1 ) ) ; XmlMessage . paramLangXML ( ) ; Document document ; document = XmlMessage . builder . parse ( in ) ; document . getDocumentElement ( ) . normalize ( ) ; String result ; if ( ( result = XmlMessage . readChild ( document , XmlMessage . ID_USER ) ) != null ) { <START_BUG> xmlSet . setIdUser ( Integer . parseInt ( result ) ) ; <END_BUG> } try { if ( ( result = XmlMessage . readChild ( document , XmlMessage . MESSAGE ) ) != null ) { xmlSet . setMessage ( result ) ; } if ( ( result = XmlMessage . readChild ( document , XmlMessage . DIALOG_ID ) ) != null ) { xmlSet . setKeyDialog ( Integer . parseInt ( result ) ) ; } } catch ( Exception e ) { XmlMessage . LOG . error ( "messageID<seq2seq4repair_space>and<seq2seq4repair_space>ID<seq2seq4repair_space>" , e ) ; XmlMessage . LOG . debug ( ( "message,<seq2seq4repair_space>ID<seq2seq4repair_space>" + ( Arrays . toString ( e . getStackTrace ( ) ) ) ) ) ; } List < String > list = new ArrayList < > ( ) ; NodeList nList = document . getElementsByTagName ( XmlMessage . LIST_USER ) ; if ( nList != null ) { for ( int temp = 0 ; temp < ( nList . getLength ( ) ) ; temp ++ ) { Node nNode = nList . item ( temp ) ; if ( ( nNode . getNodeType ( ) ) == ( Node . ELEMENT_NODE ) ) { Element eElement = ( ( Element ) ( nNode ) ) ; list . add ( eElement . getElementsByTagName ( XmlMessage . NAME ) . item ( 0 ) . getTextContent ( ) ) ; } } xmlSet . setList ( list ) ; } try { if ( ( result = XmlMessage . readChild ( document , XmlMessage . ELSE_PREFERENCE ) ) != null ) { xmlSet . setPreference ( result ) ; } } catch ( Exception e ) { XmlMessage . LOG . debug ( "else_preference<seq2seq4repair_space>" , e ) ; } if ( ( xmlSet . getIdUser ( ) ) != ( - 1 ) ) { return xmlSet ; } else { return null ; } } }

Fix:
xmlSet . setIdUser ( Long . parseLong ( result ) ) ;
Buggy code:
public class PerCflow extends PerClause { private boolean isBelow ; private Pointcut entry ; public PerCflow ( Pointcut entry , boolean isBelow ) { } public Object accept ( PatternNodeVisitor visitor , Object data ) { } public Set couldMatchKinds ( ) { } public FuzzyBoolean fastMatch ( FastMatchInfo type ) { } public FuzzyBoolean fastMatch ( Class targetType ) { } protected FuzzyBoolean matchInternal ( Shadow shadow ) { } public void resolveBindings ( IScope scope , Bindings bindings ) { } protected Test findResidueInternal ( Shadow shadow , ExposedState state ) { } public PerClause concretize ( ResolvedType inAspect ) { PerCflow ret = new PerCflow ( entry , isBelow ) ; ret . inAspect = inAspect ; if ( inAspect . isAbstract ( ) ) return ret ; Member cflowStackField = new org . aspectj . weaver . ResolvedMemberImpl ( Member . FIELD , inAspect , ( ( ( Modifier . STATIC ) | ( Modifier . PUBLIC ) ) | ( Modifier . FINAL ) ) , UnresolvedType . forName ( CFLOW_STACK_TYPE ) , NameMangler . PERCFLOW_FIELD_NAME , UnresolvedType . NONE ) ; World world = inAspect . getWorld ( ) ; CrosscuttingMembers xcut = inAspect . crosscuttingMembers ; Collection previousCflowEntries = xcut . getCflowEntries ( ) ; <START_BUG> Pointcut concreteEntry = entry . concretize ( inAspect , 0 , null ) ; <END_BUG> List innerCflowEntries = new ArrayList ( xcut . getCflowEntries ( ) ) ; innerCflowEntries . removeAll ( previousCflowEntries ) ; xcut . addConcreteShadowMunger ( Advice . makePerCflowEntry ( world , concreteEntry , isBelow , cflowStackField , inAspect , innerCflowEntries ) ) ; if ( ( inAspect . isAnnotationStyleAspect ( ) ) && ( ! ( inAspect . isAbstract ( ) ) ) ) { inAspect . crosscuttingMembers . addLateTypeMunger ( inAspect . getWorld ( ) . makePerClauseAspect ( inAspect , getKind ( ) ) ) ; } if ( ( inAspect . isAnnotationStyleAspect ( ) ) && ( ! ( inAspect . getWorld ( ) . isXnoInline ( ) ) ) ) { inAspect . crosscuttingMembers . addTypeMunger ( new org . aspectj . weaver . bcel . BcelAccessForInlineMunger ( inAspect ) ) ; } return ret ; } public void write ( DataOutputStream s ) throws IOException { } public static PerClause readPerClause ( VersionedDataInputStream s , ISourceContext context ) throws IOException { } public Kind getKind ( ) { } public String toString ( ) { } public String toDeclarationString ( ) { } }

Fix:
Pointcut concreteEntry = entry . concretize ( inAspect , inAspect , 0 , null ) ;
Buggy code:
public class NXTRecord extends Record { private static NXTRecord member = new NXTRecord ( ) ; private Name next ; private BitSet bitmap ; private NXTRecord ( ) { } private NXTRecord ( Name name , int dclass , long ttl ) { } static NXTRecord getMember ( ) { } public NXTRecord ( Name name , int dclass , long ttl , Name next , BitSet bitmap ) { } Record rrFromWire ( Name name , int type , int dclass , long ttl , int length , DataByteInputStream in ) throws IOException { } Record rdataFromString ( Name name , int dclass , long ttl , Tokenizer st , Name origin ) throws IOException { NXTRecord rec = new NXTRecord ( name , dclass , ttl ) ; rec . next = st . getName ( origin ) ; rec . bitmap = new BitSet ( ) ; while ( true ) { Tokenizer . Token t = st . get ( ) ; if ( ! ( t . isString ( ) ) ) break ; <START_BUG> int type = Type . value ( t . value ) ; <END_BUG> if ( ( type <= 0 ) || ( type > 128 ) ) throw st . exception ( ( "Invalid<seq2seq4repair_space>type:<seq2seq4repair_space>" + ( t . value ) ) ) ; rec . bitmap . set ( type ) ; } st . unget ( ) ; return rec ; } public String rdataToString ( ) { } public Name getNext ( ) { } public BitSet getBitmap ( ) { } void rrToWire ( DataByteOutputStream out , Compression c , boolean canonical ) { } }

Fix:
int type = Type . value ( t . value , true ) ;
Buggy code:
@ Options ( prefix = "cpa.predicate" ) public final class AbstractionManager { public static interface AbstractionPredicatesMXBean { int getNumberOfPredicates ( ) { } String getPredicates ( ) { } } private class AbstractionPredicatesMBean extends AbstractMBean implements AbstractionManager . AbstractionPredicatesMXBean { public AbstractionPredicatesMBean ( ) { } @ Override public int getNumberOfPredicates ( ) { } @ Override public String getPredicates ( ) { } } private volatile int numberOfPredicates = 0 ; private final LogManager logger ; private final RegionManager rmgr ; private final FormulaManagerView fmgr ; private final Map < Region , AbstractionPredicate > absVarToPredicate = Maps . newHashMap ( ) ; private final Map < BooleanFormula , AbstractionPredicate > symbVarToPredicate = Maps . newHashMap ( ) ; private final Map < BooleanFormula , AbstractionPredicate > atomToPredicate = Maps . newHashMap ( ) ; @ Option ( secure = true , name = "abs.useCache" , description = "use<seq2seq4repair_space>caching<seq2seq4repair_space>of<seq2seq4repair_space>region<seq2seq4repair_space>to<seq2seq4repair_space>formula<seq2seq4repair_space>conversions" ) private boolean useCache = true ; private final Map < Region , BooleanFormula > toConcreteCache ; private BooleanFormulaManagerView bfmgr ; public AbstractionManager ( RegionManager pRmgr , FormulaManagerView pFmgr , Configuration config , LogManager pLogger ) throws InvalidConfigurationException { } public int getNumberOfPredicates ( ) { } public AbstractionPredicate makePredicate ( BooleanFormula atom ) { } public AbstractionPredicate makeFalsePredicate ( ) { } private AbstractionPredicate getPredicate ( BooleanFormula var ) { } public BooleanFormula toConcrete ( Region af ) { } public boolean entails ( Region f1 , Region f2 ) throws InterruptedException , SolverException { } public Set < AbstractionPredicate > extractPredicates ( Region af ) { } public Region buildRegionFromFormula ( BooleanFormula pF ) { } public Region buildRegionFromFormulaWithUnknownAtoms ( BooleanFormula pF ) { return rmgr . fromFormula ( pF , fmgr , new Function < BooleanFormula , Region > ( ) { @ Override public Region apply ( BooleanFormula pInput ) { <START_BUG> if ( symbVarToPredicate . containsKey ( pInput ) ) { <END_BUG> return atomToPredicate . get ( pInput ) . getAbstractVariable ( ) ; } return makePredicate ( pInput ) . getAbstractVariable ( ) ; } } ) ; } public AbstractionManager . RegionCreator getRegionCreator ( ) { } public class RegionCreator { public RegionBuilder newRegionBuilder ( ShutdownNotifier pShutdownNotifier ) { } public Region makeTrue ( ) { } public Region makeFalse ( ) { } public Region makeNot ( Region f ) { } public Region makeAnd ( Region f1 , Region f2 ) { } public Region makeOr ( Region f1 , Region f2 ) { } public Region makeEqual ( Region f1 , Region f2 ) { } public Region makeIte ( Region f1 , Region f2 , Region f3 ) { } public Region makeExists ( Region f1 , Region f2 ) { } public Region getPredicate ( BooleanFormula var ) { } } }

Fix:
if ( atomToPredicate . containsKey ( pInput ) ) {
Buggy code:
public class TripMapActivity extends MapActivity { public static final String TRIP_EXTRA = "trip" ; public void onCreate ( Bundle savedInstanceState ) { super . onCreate ( savedInstanceState ) ; setContentView ( activity_trip_map ) ; MapView mapView = ( ( MapView ) ( findViewById ( map_view ) ) ) ; mapView . setBuiltInZoomControls ( true ) ; Trip trip = ( ( Trip ) ( getIntent ( ) . getParcelableExtra ( TripMapActivity . TRIP_EXTRA ) ) ) ; ActionBar actionBar = getActionBar ( ) ; actionBar . setDisplayHomeAsUpEnabled ( true ) ; actionBar . setTitle ( Trip . formatStationNames ( trip ) ) ; <START_BUG> actionBar . setSubtitle ( ( ( ( trip . getAgencyName ( ) ) + "<seq2seq4repair_space>" ) + ( trip . getRouteName ( ) ) ) ) ; <END_BUG> int startMarkerId = drawable . marker_start ; int endMarkerId = drawable . marker_end ; TripMapActivity . StationItemizedOverlay stationsOverlay = new TripMapActivity . StationItemizedOverlay ( null ) ; stationsOverlay . addStation ( trip . getStartStation ( ) , startMarkerId ) ; stationsOverlay . addStation ( trip . getEndStation ( ) , endMarkerId ) ; mapView . getOverlays ( ) . add ( stationsOverlay ) ; if ( ( stationsOverlay . getCenter ( ) ) != null ) { MapController controller = mapView . getController ( ) ; TripMapActivity . centerAroundOverlayItems ( controller , stationsOverlay ) ; } } @ Override protected boolean isRouteDisplayed ( ) { } @ Override public boolean onOptionsItemSelected ( MenuItem item ) { } private class StationItemizedOverlay extends ItemizedOverlay < OverlayItem > { private ArrayList < OverlayItem > mMapOverlays = new ArrayList < OverlayItem > ( ) ; public StationItemizedOverlay ( Drawable drawable ) { } @ Override protected OverlayItem createItem ( int i ) { } @ Override public int size ( ) { } private void addStation ( Station station , int markerId ) { } } private static void centerAroundOverlayItems ( MapController controller , TripMapActivity . StationItemizedOverlay itemizedOverlay ) { } No newline ; at end ; of file ; }

Fix:
actionBar . setSubtitle ( ( ( trip . getRouteName ( ) ) == null ? trip . getAgencyName ( ) : String . format ( "%s<seq2seq4repair_space>%s" , trip . getAgencyName ( ) , trip . getRouteName ( ) ) ) ) ;
Buggy code:
public class ContactTest { ContactImpl contact ; @ Before public void buildUp ( ) { <START_BUG> contact = new ContactImpl ( 100 , "Mark<seq2seq4repair_space>Holt" ) ; <END_BUG> } @ Test public void tests_getID_returns_ContactID ( ) { } @ Test public void tests_getName_returns_ContactName ( ) { } @ Test public void tests_getNotes_returns_NULL_ifNoNotes_returnsNotes_ifNotesAdded ( ) { } }

Fix:
contact = new ContactImpl ( 100 , "Pierre<seq2seq4repair_space>Meyer" ) ;
Buggy code:
public class StatsVisitorsAndViewsFragment extends StatsAbstractFragment implements StatsBarGraph . OnGestureListener { public static final String TAG = StatsVisitorsAndViewsFragment . class . getSimpleName ( ) ; private static final String ARG_SELECTED_GRAPH_BAR = "ARG_SELECTED_GRAPH_BAR" ; private static final String ARG_SELECTED_OVERVIEW_ITEM = "ARG_SELECTED_OVERVIEW_ITEM" ; private LinearLayout mGraphContainer ; private StatsBarGraph mGraphView ; private GraphViewSeries mCurrentSeriesOnScreen ; private LinearLayout mModuleButtonsContainer ; private TextView mDateTextView ; private String [ ] mStatsDate ; private StatsVisitorsAndViewsFragment . OnDateChangeListener mListener ; final StatsVisitorsAndViewsFragment . OverviewLabel [ ] overviewItems = new StatsVisitorsAndViewsFragment . OverviewLabel [ ] { StatsVisitorsAndViewsFragment . OverviewLabel . VIEWS , StatsVisitorsAndViewsFragment . OverviewLabel . VISITORS , StatsVisitorsAndViewsFragment . OverviewLabel . LIKES , StatsVisitorsAndViewsFragment . OverviewLabel . COMMENTS } ; private Serializable mVisitsData ; private int mSelectedOverviewItemIndex = 0 ; private int mSelectedBarGraphBarIndex = - 1 ; public interface OnDateChangeListener { public void onDateChanged ( String blogID , StatsTimeframe timeframe , String newDate ) { } } @ Override public void onAttach ( Activity activity ) { } @ Override public View onCreateView ( LayoutInflater inflater , ViewGroup container , Bundle savedInstanceState ) { } private OnClickListener TopButtonsOnClickListener = new View . OnClickListener ( ) { @ Override public void onClick ( View v ) { } } ; @ Override public void onCreate ( Bundle savedInstanceState ) { } @ Override public void onSaveInstanceState ( Bundle outState ) { } @ Override public void onPause ( ) { } @ Override public void onResume ( ) { } private VisitModel [ ] getDataToShowOnGraph ( VisitsModel visitsData ) { } private void updateUI ( ) { } private void updateUIBelowTheGraph ( int itemPosition ) { } private String getDateForDisplayInLabels ( String date , StatsTimeframe timeframe ) { } private String getDateLabelForBarInGraph ( String dateToFormat ) { } private void setupNoResultsUI ( boolean isLoading ) { } @ Override protected String getTitle ( ) { } private final BroadcastReceiver mReceiver = new BroadcastReceiver ( ) { @ Override public void onReceive ( Context context , Intent intent ) { } } ; @ Override public void onBarTapped ( int tappedBar ) { } private enum OverviewLabel { VIEWS ( string . stats_views ) , VISITORS ( string . stats_visitors ) , LIKES ( string . stats_likes ) , COMMENTS ( string . stats_comments ) ; private final int mLabelResId ; private OverviewLabel ( int labelResId ) { } public String getLabel ( ) { <START_BUG> return WordPress . getContext ( ) . getString ( mLabelResId ) ; <END_BUG> } public static String [ ] toStringArray ( StatsVisitorsAndViewsFragment . OverviewLabel [ ] timeframes ) { } } @ Override protected void resetDataModel ( ) { } }

Fix:
return WordPress . getContext ( ) . getString ( mLabelResId ) . toUpperCase ( ) ;
Buggy code:
public class MainActivity extends Activity { String screenString = "" ; TextView screen ; TextView opScreen ; Double number1 = null ; Double number2 = null ; String operator = "" ; Button plusButton ; Button subButton ; Button divButton ; Button multButton ; Button srButton ; Button perButton ; Button acButton ; Button backButton ; Button equalButton ; @ Override protected void onCreate ( Bundle savedInstanceState ) { } public void press1 ( View view ) { } public void press2 ( View view ) { } public void press3 ( View view ) { } public void press4 ( View view ) { } public void press5 ( View view ) { } public void press6 ( View view ) { } public void press7 ( View view ) { } public void press8 ( View view ) { } public void press9 ( View view ) { } public void press0 ( View view ) { } public void pressPoint ( View view ) { } public void pressBack ( View view ) { } public void pressAC ( View view ) { } public void pressSqrt ( View view ) { } public void pressPercent ( View view ) { } public void pressPlus ( View view ) { } public void pressMinus ( View view ) { } public void pressMult ( View view ) { } public void pressDiv ( View view ) { } public void pressEqual ( View view ) { <START_BUG> if ( ( ! ( operator . equals ( "" ) ) ) && ( ! ( screenString . equals ( "" ) ) ) ) { <END_BUG> if ( operator . equals ( "SR" ) ) { pressSqrt ( view ) ; } else { if ( ( number2 ) == null ) { number2 = Double . parseDouble ( screenString ) ; } number1 = calculate ( number1 , number2 , operator ) ; BigDecimal bd = new BigDecimal ( number1 ) ; screenString = String . valueOf ( MainActivity . formatNumber ( bd ) ) ; displayOps ( "" , "" ) ; displayScreen ( screenString ) ; } } } private Double calculate ( Double num1 , Double num2 , String operator ) { } private void operation ( String op ) { } private void displayScreen ( String screenString ) { } private void displayOps ( String number , String operator ) { } private static String formatNumber ( BigDecimal number ) { } private void pressKey ( String key ) { } }

Fix:
if ( ( ( ! ( operator . equals ( "" ) ) ) && ( ! ( screenString . equals ( "." ) ) ) ) && ( ! ( screenString . equals ( "" ) ) ) ) {
Buggy code:
public class Lifesteal extends CEnchantment { public double heal ; public Lifesteal ( String originalName , Application app , Cause cause , int enchantProbability , int occurrenceChance ) { } @ Override public void effect ( Event e , ItemStack item , int level ) { EntityDamageByEntityEvent event = ( ( EntityDamageByEntityEvent ) ( e ) ) ; Player damager = ( ( Player ) ( event . getDamager ( ) ) ) ; if ( damager . getGameMode ( ) . equals ( CREATIVE ) ) return ; double newHeal = ( ( ( ( org . bukkit . entity . Damageable ) ( damager ) ) . getHealth ( ) ) + ( heal ) ) + level ; if ( newHeal < ( ( ( org . bukkit . entity . Damageable ) ( damager ) ) . getMaxHealth ( ) ) ) <START_BUG> damager . setHealth ( ( ( ( ( org . bukkit . entity . Damageable ) ( damager ) ) . getHealth ( ) ) + newHeal ) ) ; <END_BUG> else damager . setHealth ( ( ( org . bukkit . entity . Damageable ) ( damager ) ) . getMaxHealth ( ) ) ; } @ Override public void initConfigEntries ( ) { } }

Fix:
damager . setHealth ( newHeal ) ;
Buggy code:
public class AbstractFolderTst extends TestCase { protected AbstractMessageFolder sourceFolder ; protected AbstractMessageFolder destFolder ; private Set folders ; private static int folderId = 0 ; private MailboxTstFactory factory ; public AbstractFolderTst ( String test ) { } public AbstractFolderTst ( MailboxTstFactory factory , String test ) { } protected void setUp ( ) throws Exception { File file = new File ( "test_config" ) ; file . mkdir ( ) ; new Config ( file ) ; Logging . DEBUG = true ; Logging . createDefaultHandler ( ) ; new MailMain ( ) . init ( ) ; new AddressbookMain ( ) . init ( ) ; <START_BUG> PluginManager . getInstance ( ) . initPlugins ( ) ; <END_BUG> folders = new HashSet ( ) ; sourceFolder = factory . createFolder ( ( ( AbstractFolderTst . folderId ) ++ ) ) ; folders . add ( sourceFolder ) ; destFolder = factory . createFolder ( ( ( AbstractFolderTst . folderId ) ++ ) ) ; folders . add ( destFolder ) ; } public AbstractMessageFolder createFolder ( ) { } protected void tearDown ( ) throws Exception { } public AbstractMessageFolder getSourceFolder ( ) { } public AbstractMessageFolder getDestFolder ( ) { } }

Fix:
PluginManager . getInstance ( ) . initCorePlugins ( ) ;
Buggy code:
public class AsciiType extends BytesType { public static final AsciiType instance = new AsciiType ( ) ; AsciiType ( ) { } @ Override public String getString ( ByteBuffer bytes ) { } public ByteBuffer fromString ( String source ) { <START_BUG> return ByteBuffer . wrap ( source . getBytes ( Charsets . US_ASCII ) ) ; <END_BUG> } public void validate ( ByteBuffer bytes ) throws MarshalException { } }

Fix:
return ByteBufferUtil . bytes ( source , Charsets . US_ASCII ) ;
Buggy code:
public class HybridUI extends AbstractUIPlugin { public static final String PLUGIN_ID = PlatformConstants . HYBRID_UI_PLUGIN_ID ; private static ILog logger ; private static HybridUI plugin ; private final RestorePluginsListener pluginRestoreListener ; public HybridUI ( ) { } public void start ( BundleContext context ) throws Exception { } public void stop ( BundleContext context ) throws Exception { } public static HybridUI getDefault ( ) { } public static void log ( int status , String message , Throwable throwable ) { <START_BUG> HybridUI . logger . log ( new Status ( status , message , HybridUI . PLUGIN_ID , throwable ) ) ; <END_BUG> } public static ImageDescriptor getImageDescriptor ( String name , String path ) { } public static List < PlatformImage > getPlatformImages ( ) { } public static List < HybridMobileStatusExtension > getHybridMobileStatusExtensions ( ) { } }

Fix:
HybridUI . logger . log ( new Status ( status , HybridUI . PLUGIN_ID , message , throwable ) ) ;
Buggy code:
public class IsPingable extends ProjectComponent implements Condition { private String host ; public static final int DEFAULT_TIMEOUT = 30 ; private int timeout = IsPingable . DEFAULT_TIMEOUT ; public static final String ERROR_NO_HOSTNAME = "No<seq2seq4repair_space>hostname<seq2seq4repair_space>defined" ; public static final String ERROR_BAD_TIMEOUT = "Invalid<seq2seq4repair_space>timeout<seq2seq4repair_space>value" ; public static final String ERROR_UNKNOWN_HOST = "Unknown<seq2seq4repair_space>host:" ; public static final String ERROR_ON_NETWORK = "network<seq2seq4repair_space>error<seq2seq4repair_space>to<seq2seq4repair_space>" ; public void setHost ( String host ) { } public void setTimeout ( int timeout ) { } public boolean eval ( ) throws BuildException { <START_BUG> if ( ( ( host ) == null ) && ( ( host . length ( ) ) == 0 ) ) { <END_BUG> throw new BuildException ( IsPingable . ERROR_NO_HOSTNAME ) ; } if ( ( timeout ) < 0 ) { throw new BuildException ( IsPingable . ERROR_BAD_TIMEOUT ) ; } try { InetAddress address = InetAddress . getByName ( host ) ; return address . isReachable ( ( ( timeout ) * 1000 ) ) ; } catch ( UnknownHostException e ) { log ( ( ( IsPingable . ERROR_UNKNOWN_HOST ) + ( host ) ) , MSG_VERBOSE ) ; return false ; } catch ( IOException e ) { log ( ( ( ( ( IsPingable . ERROR_ON_NETWORK ) + ( host ) ) + ":<seq2seq4repair_space>" ) + ( e . toString ( ) ) ) , MSG_VERBOSE ) ; return false ; } } }

Fix:
if ( ( ( host ) == null ) || ( ( host . length ( ) ) == 0 ) ) {
Buggy code:
public class CreateFolderDialog extends JDialog implements ActionListener { protected boolean bool = false ; protected JTextField textField ; protected JButton okButton ; protected JButton cancelButton ; protected JButton helpButton ; protected JComboBox typeBox ; protected JTree tree ; protected String name ; protected TreePath selected ; public CreateFolderDialog ( TreePath selected ) { } protected void layoutComponents ( ) { } protected void initComponents ( ) { } public void showDialog ( ) { } public String getName ( ) { } public FolderTreeNode getSelected ( ) { } public boolean success ( ) { } public void actionPerformed ( ActionEvent e ) { String action = e . getActionCommand ( ) ; if ( action . equals ( "OK" ) ) { name = textField . getText ( ) . trim ( ) ; if ( ( name . indexOf ( '//' ) ) != ( - 1 ) ) { JOptionPane . showMessageDialog ( null , MailResourceLoader . getString ( "dialog" , "folder" , "error_char_text" ) , MailResourceLoader . getString ( "dialog" , "folder" , "error_char_title" ) , JOptionPane . ERROR_MESSAGE ) ; return ; } bool = true ; <START_BUG> dispose ( ) ; <END_BUG> } else if ( action . equals ( "CANCEL" ) ) { bool = false ; dispose ( ) ; } } }

Fix:
setVisible ( false ) ;
Buggy code:
public class LambdaAbstractionViewController extends LambdaValueViewController { private final TextureRegion front ; private final TextureRegion center ; private final TextureRegion back ; private final TextureRegion frontMask ; private final TextureRegion centerMask ; private final TextureRegion backMask ; private final Animation animation ; private boolean animate ; private float magicStateTime ; public LambdaAbstractionViewController ( LambdaAbstraction linkedTerm , LambdaNodeViewController parent , LambdaTermViewController viewController ) { } @ Override public float getMinWidth ( ) { } @ Override public void draw ( Batch batch , float alpha ) { updateColorAnimation ( ) ; batch . draw ( back , getX ( ) , getY ( ) , BLOCK_WIDTH , BLOCK_HEIGHT ) ; batch . setColor ( getCurrentColor ( ) . r , getCurrentColor ( ) . g , getCurrentColor ( ) . b , 1.0F ) ; batch . draw ( backMask , getX ( ) , getY ( ) , BLOCK_WIDTH , BLOCK_HEIGHT ) ; batch . setColor ( 1.0F , 1.0F , 1.0F , 1.0F ) ; float x ; for ( x = ( getX ( ) ) + ( BLOCK_WIDTH ) ; x < ( ( ( ( getX ( ) ) + ( getWidth ( ) ) ) - ( BLOCK_WIDTH ) ) - ( EPSILON ) ) ; x += BLOCK_WIDTH ) { batch . draw ( center , x , getY ( ) , BLOCK_WIDTH , BLOCK_HEIGHT ) ; batch . setColor ( getCurrentColor ( ) . r , getCurrentColor ( ) . g , getCurrentColor ( ) . b , 1.0F ) ; batch . draw ( centerMask , x , getY ( ) , BLOCK_WIDTH , BLOCK_HEIGHT ) ; batch . setColor ( 1.0F , 1.0F , 1.0F , 1.0F ) ; } batch . draw ( front , x , getY ( ) , BLOCK_WIDTH , BLOCK_HEIGHT ) ; batch . setColor ( getCurrentColor ( ) . r , getCurrentColor ( ) . g , getCurrentColor ( ) . b , 1.0F ) ; batch . draw ( frontMask , x , getY ( ) , BLOCK_WIDTH , BLOCK_HEIGHT ) ; batch . setColor ( 1.0F , 1.0F , 1.0F , 1.0F ) ; <START_BUG> super . draw ( batch , alpha ) ; <END_BUG> synchronized ( getViewController ( ) ) { if ( animate ) { batch . draw ( animation . getKeyFrame ( magicStateTime ) , x , getY ( ) , BLOCK_WIDTH , BLOCK_HEIGHT ) ; magicStateTime += graphics . getDeltaTime ( ) ; if ( isMagicAnimationFinished ( ) ) { animate = false ; getViewController ( ) . notifyAll ( ) ; } } } } public void animateMagic ( ) { } public boolean isMagicAnimationFinished ( ) { } @ Override public boolean equals ( Object other ) { } }

Fix:
drawVanishAnimation ( batch , alpha ) ;
Buggy code:
public class GameScreen implements Screen { public OrthographicCamera camera ; private Viewport viewport ; NPC [ ] enemies ; ENEMY [ ] randoms ; public TiledMapTileLayer collision ; public TiledMapRenderer tiledmaprenderer ; public int [ ] background = new int [ 3 ] ; public int [ ] foreground = new int [ 1 ] ; public boolean lWalk ; public boolean rWalk ; public boolean uWalk ; public boolean dWalk ; public boolean dial ; public boolean newDial ; public boolean store ; public boolean advising ; private boolean attackable ; private boolean safe ; private int recently_attacked ; Random random = new Random ( ) ; public int location ; public boolean load ; public CharacterDialogue window ; public ShopMenu shop_window ; public GameScreen ( ) { } public void setMap ( TiledMap tiledmap , int x , int y , int loc ) { } private void drawEnemies ( ) { } private void checkForEnemy ( float delta ) { if ( collision . getCell ( ( ( ( int ) ( camera . position . x ) ) // ( Utils . MAP_RESOLUTION ) ) , ( ( ( int ) ( camera . position . y ) ) // ( Utils . MAP_RESOLUTION ) ) ) . getTile ( ) . getProperties ( ) . containsKey ( "enemy" ) ) { int temp = Integer . valueOf ( ( ( String ) ( collision . getCell ( ( ( ( int ) ( camera . position . x ) ) // ( Utils . MAP_RESOLUTION ) ) , ( ( ( int ) ( camera . position . y ) ) // ( Utils . MAP_RESOLUTION ) ) ) . getTile ( ) . getProperties ( ) . get ( "number" ) ) ) ) ; <START_BUG> if ( ! ( enemies [ temp ] . getTriggered ( ) ) ) { <END_BUG> attackable = false ; lWalk = false ; rWalk = false ; uWalk = false ; dWalk = false ; enemies [ temp ] . move ( delta , camera . position . x , camera . position . y ) ; hero . setMove ( false ) ; } else { hero . setMove ( true ) ; } } } public void interact ( ) { } @ Override public void render ( float delta ) { } public void walk ( float delta ) { } public void randomEncounter ( ) { } @ Override public void show ( ) { } @ Override public void resize ( int width , int height ) { } @ Override public void pause ( ) { } @ Override public void resume ( ) { } @ Override public void hide ( ) { } @ Override public void dispose ( ) { } }

Fix:
if ( ! ( enemies [ temp ] . triggered ) ) {
Buggy code:
public class BehaviorRequestTarget extends AbstractListenerInterfaceRequestTarget { public BehaviorRequestTarget ( final Page page , final Component component , final RequestListenerInterface listener ) { } public BehaviorRequestTarget ( final Page page , final Component component , final RequestListenerInterface listener , final RequestParameters requestParameters ) { } public final void processEvents ( final RequestCycle requestCycle ) { onProcessEvents ( requestCycle ) ; final Component component = getTarget ( ) ; final String id = getRequestParameters ( ) . getBehaviorId ( ) ; if ( id == null ) { throw new IllegalStateException ( ( "Parameter<seq2seq4repair_space>behaviorId<seq2seq4repair_space>was<seq2seq4repair_space>not<seq2seq4repair_space>provided:<seq2seq4repair_space>unable<seq2seq4repair_space>to<seq2seq4repair_space>locate<seq2seq4repair_space>listener.<seq2seq4repair_space>Component:<seq2seq4repair_space>" + ( component . toString ( ) ) ) ) ; } final int idAsInt = Integer . parseInt ( id ) ; final IBehaviorListener behaviorListener = ( ( IBehaviorListener ) ( component . getBehaviors ( ) . get ( idAsInt ) ) ) ; if ( behaviorListener == null ) { throw new IllegalStateException ( ( ( ( "No<seq2seq4repair_space>behavior<seq2seq4repair_space>listener<seq2seq4repair_space>found<seq2seq4repair_space>with<seq2seq4repair_space>behaviorId<seq2seq4repair_space>" + id ) + ";<seq2seq4repair_space>Component:<seq2seq4repair_space>" ) + ( component . toString ( ) ) ) ) ; } <START_BUG> behaviorListener . onRequest ( component ) ; <END_BUG> } }

Fix:
behaviorListener . onRequest ( ) ;
Buggy code:
public class SimulatedAnnealing extends Heuristic { protected Schedule schedule ; protected Schedule currentSchedule ; protected int currentValue ; private double temperature ; private double tempchange ; private int deltaval ; private int day1 ; private int period1 ; private int room1 ; private int day2 ; private int period2 ; private int room2 ; private int bestCourse1 ; private int bestCourse2 ; private Random Rand = new XORShiftRandom ( ) ; public SimulatedAnnealing ( double temperature , double tempchange ) throws IOException { } @ Override public Schedule search ( Schedule schedule ) throws IOException { } private double GetProbability ( ) { <START_BUG> return Math . exp ( ( ( deltaval ) // ( temperature ) ) ) ; <END_BUG> } }

Fix:
return Math . exp ( ( ( - ( deltaval ) ) // ( temperature ) ) ) ;
Buggy code:
public class DefendClickListener implements OnClickListener { @ Override public void onClick ( View v ) { <START_BUG> activity . PCMakesDefenceMove ( ) ; <END_BUG> } }

Fix:
GameActivity . getInstance ( ) . PCMakesDefenceMove ( ) ;
Buggy code:
public abstract class HeaderlessColumn < T > extends AbstractColumn < T > { private static final long serialVersionUID = 1L ; public HeaderlessColumn ( ) { } @ Override <START_BUG> public Component getHeader ( String componentId ) { <END_BUG> Component header = super . getHeader ( componentId ) ; return header . setEscapeModelStrings ( false ) ; } }

Fix:
public Component getHeader ( final String componentId ) {
Buggy code:
public class DefaultNode implements Node { public DefaultNode ( ) { } public String getNodeName ( ) { } public String getNodeValue ( ) throws DOMException { } public short getNodeType ( ) { } public Node getParentNode ( ) { } public NodeList getChildNodes ( ) { } public Node getFirstChild ( ) { } public Node getLastChild ( ) { } public Node getPreviousSibling ( ) { } public Node getNextSibling ( ) { } public NamedNodeMap getAttributes ( ) { } public Document getOwnerDocument ( ) { } public boolean hasChildNodes ( ) { } public Node cloneNode ( boolean deep ) { } public void normalize ( ) { } public boolean isSupported ( String feature , String version ) { } public String getNamespaceURI ( ) { } public String getPrefix ( ) { } public String getLocalName ( ) { } public String getBaseURI ( ) { } public boolean hasAttributes ( ) { } public void setNodeValue ( String nodeValue ) throws DOMException { } public Node insertBefore ( Node newChild , Node refChild ) throws DOMException { } public Node replaceChild ( Node newChild , Node oldChild ) throws DOMException { } public Node removeChild ( Node oldChild ) throws DOMException { } public Node appendChild ( Node newChild ) throws DOMException { } public void setPrefix ( String prefix ) throws DOMException { } public short compareDocumentPosition ( Node other ) { } public String getTextContent ( ) throws DOMException { } public void setTextContent ( String textContent ) throws DOMException { } public boolean isSameNode ( Node other ) { } public String lookupPrefix ( String namespaceURI ) { } public boolean isDefaultNamespace ( String namespaceURI ) { } public String lookupNamespaceURI ( String prefix ) { } public boolean isEqualNode ( Node arg ) { } <START_BUG> public Node getFeature ( String feature , String version ) { <END_BUG> return null ; } public Object setUserData ( String key , Object data , UserDataHandler handler ) { } public Object getUserData ( String key ) { } }

Fix:
public Object getFeature ( String feature , String version ) {
Buggy code:
public abstract class AbstractAjaxTimerBehavior extends AbstractDefaultAjaxBehavior { private static final long serialVersionUID = 1L ; private Duration updateInterval ; private boolean stopped = false ; private boolean headRendered = false ; public AbstractAjaxTimerBehavior ( final Duration updateInterval ) { } public final void stop ( ) { } protected final void setUpdateInterval ( Duration updateInterval ) { } public final Duration getUpdateInterval ( ) { } @ Override public void renderHead ( IHeaderResponse response ) { } protected final String getJsTimeoutCall ( final Duration updateInterval ) { } @ Override protected CharSequence getCallbackScript ( ) { <START_BUG> return generateCallbackScript ( ( ( "wicketAjaxGet('" + ( getCallbackUrl ( onlyTargetActivePage ( ) ) ) ) + "'" ) ) ; <END_BUG> } @ Override protected CharSequence getPreconditionScript ( ) { } protected boolean onlyTargetActivePage ( ) { } @ Override protected final void respond ( final AjaxRequestTarget target ) { } protected abstract void onTimer ( final AjaxRequestTarget target ) { } }

Fix:
return generateCallbackScript ( ( ( "wicketAjaxGet('" + ( getCallbackUrl ( ) ) ) + "'" ) ) ;
Buggy code:
public class ModClusterAddMetric implements OperationStepHandler , DescriptionProvider { static final ModClusterAddMetric INSTANCE = new ModClusterAddMetric ( ) ; @ Override public ModelNode getModelDescription ( Locale locale ) { } @ Override public void execute ( OperationContext context , ModelNode operation ) throws OperationFailedException { <START_BUG> if ( context . getProcessType ( ) . isServer ( ) ) { <END_BUG> context . addStep ( new OperationStepHandler ( ) { @ Override public void execute ( OperationContext context , ModelNode operation ) throws OperationFailedException { final ModelNode dynamicLoadProvider = context . readResourceForUpdate ( EMPTY_ADDRESS ) . getModel ( ) . get ( DYNAMIC_LOAD_PROVIDER ) ; final ModelNode metric = new ModelNode ( ) ; List < Property > list = operation . asPropertyList ( ) ; Iterator < Property > it = list . iterator ( ) ; while ( it . hasNext ( ) ) { Property prop = it . next ( ) ; if ( prop . getName ( ) . equals ( "property" ) ) { String properties = prop . getValue ( ) . asString ( ) ; ModelNode props = ModelNode . fromString ( properties ) ; metric . get ( "property" ) . set ( props ) ; } else { metric . get ( prop . getName ( ) ) . set ( prop . getValue ( ) . asString ( ) ) ; } } if ( ! ( metric . get ( "type" ) . isDefined ( ) ) ) { throw new OperationFailedException ( new ModelNode ( ) . set ( ModClusterMessages . MESSAGES . typeAttributeRequired ( "add-metric" ) ) ) ; } if ( ! ( dynamicLoadProvider . isDefined ( ) ) ) { dynamicLoadProvider . get ( HISTORY ) . set ( 9 ) ; dynamicLoadProvider . get ( DECAY ) . set ( 2 ) ; } replaceMetric ( dynamicLoadProvider , metric ) ; context . completeStep ( ) ; } private void replaceMetric ( ModelNode dynamicLoadProvider , ModelNode metric ) { List < ModelNode > newlist = Collections . < ModelNode > emptyList ( ) ; if ( dynamicLoadProvider . get ( LOAD_METRIC ) . isDefined ( ) ) { List < ModelNode > list = dynamicLoadProvider . get ( LOAD_METRIC ) . asList ( ) ; String type = metric . get ( "type" ) . asString ( ) ; Iterator < ModelNode > it = list . iterator ( ) ; dynamicLoadProvider . get ( LOAD_METRIC ) . set ( newlist ) ; while ( it . hasNext ( ) ) { ModelNode node = it . next ( ) ; if ( ! ( node . get ( "type" ) . asString ( ) . equals ( type ) ) ) { dynamicLoadProvider . get ( LOAD_METRIC ) . add ( node ) ; } } } else { dynamicLoadProvider . get ( LOAD_METRIC ) . set ( newlist ) ; } dynamicLoadProvider . get ( LOAD_METRIC ) . add ( metric ) ; } } , MODEL ) ; } context . completeStep ( ) ; } }

Fix:
if ( context . isNormalServer ( ) ) {
Buggy code:
public class Listeners implements Listener { private Main plugin ; public Listeners ( Main instance ) { } @ EventHandler public void onInteract ( PlayerInteractEvent event ) { } @ EventHandler public void onSignChange ( SignChangeEvent event ) { } @ EventHandler public void onBlockBreak ( BlockBreakEvent event ) { Player player = event . getPlayer ( ) ; String playerName = player . getName ( ) ; Block block = event . getBlock ( ) ; if ( ( ( block . getType ( ) ) == ( Material . WALL_SIGN ) ) || ( ( block . getType ( ) ) == ( Material . SIGN_POST ) ) ) { BlockState blockState = block . getState ( ) ; Sign sign = ( ( Sign ) ( blockState ) ) ; String line0 = sign . getLine ( 0 ) ; if ( ( line0 . equalsIgnoreCase ( "[warp]" ) ) && ( plugin . signProtected ) ) { String line2 = sign . getLine ( 2 ) ; Boolean isOwner = playerName . equals ( line2 ) ; Boolean hasPerm = player . hasPermission ( "itemstowarp.warp.sign.removeany" ) ; <START_BUG> if ( ( ! isOwner ) || ( ! hasPerm ) ) { <END_BUG> event . setCancelled ( true ) ; player . sendMessage ( plugin . Util . parseColors ( "^redYou<seq2seq4repair_space>do<seq2seq4repair_space>not<seq2seq4repair_space>have<seq2seq4repair_space>permission<seq2seq4repair_space>to<seq2seq4repair_space>remove<seq2seq4repair_space>sign<seq2seq4repair_space>warps." ) ) ; sign . update ( ) ; } } } } }

Fix:
if ( ( ! isOwner ) && ( ! hasPerm ) ) {
Buggy code:
public final class CTypes { private static class CanonicalCTypeEquivalence extends Equivalence < CType > { private static final CTypes . CanonicalCTypeEquivalence INSTANCE = new CTypes . CanonicalCTypeEquivalence ( ) ; @ Override protected boolean doEquivalent ( CType pA , CType pB ) { } @ Override protected int doHash ( CType pT ) { } } public static Equivalence < CType > canonicalTypeEquivalence ( ) { } public static < T extends CType > T withoutConst ( T type ) { } public static < T extends CType > T withConst ( T type ) { } public static < T extends CType > T withoutVolatile ( T type ) { } public static < T extends CType > T withVolatile ( T type ) { if ( type instanceof CProblemType ) { return type ; } <START_BUG> if ( type . isConst ( ) ) { <END_BUG> return type ; } @ SuppressWarnings ( "unchecked" ) T result = ( ( T ) ( type . accept ( CTypes . ForceVolatileVisitor . TRUE ) ) ) ; return result ; } private static enum ForceConstVisitor implements CTypeVisitor < CType , RuntimeException > { FALSE ( false ) , TRUE ( true ) ; private final boolean constValue ; private ForceConstVisitor ( boolean pConstValue ) { } @ Override public CArrayType visit ( CArrayType t ) { } @ Override public CCompositeType visit ( CCompositeType t ) { } @ Override public CElaboratedType visit ( CElaboratedType t ) { } @ Override public CEnumType visit ( CEnumType t ) { } @ Override public CFunctionType visit ( CFunctionType t ) { } @ Override public CPointerType visit ( CPointerType t ) { } @ Override public CProblemType visit ( CProblemType t ) { } @ Override public CSimpleType visit ( CSimpleType t ) { } @ Override public CTypedefType visit ( CTypedefType t ) { } @ Override public CType visit ( CVoidType t ) { } } private static enum ForceVolatileVisitor implements CTypeVisitor < CType , RuntimeException > { FALSE ( false ) , TRUE ( true ) ; private final boolean volatileValue ; private ForceVolatileVisitor ( boolean pVolatileValue ) { } @ Override public CArrayType visit ( CArrayType t ) { } @ Override public CCompositeType visit ( CCompositeType t ) { } @ Override public CElaboratedType visit ( CElaboratedType t ) { } @ Override public CEnumType visit ( CEnumType t ) { } @ Override public CFunctionType visit ( CFunctionType t ) { } @ Override public CPointerType visit ( CPointerType t ) { } @ Override public CProblemType visit ( CProblemType t ) { } @ Override public CSimpleType visit ( CSimpleType t ) { } @ Override public CTypedefType visit ( CTypedefType t ) { } @ Override public CType visit ( CVoidType t ) { } } }

Fix:
if ( type . isVolatile ( ) ) {
Buggy code:
public class PoorOreItem extends ItemBlock { private PoorOre poorOre ; public PoorOreItem ( Block poorOre ) { } @ Override public String getItemStackDisplayName ( ItemStack itemStack ) { String prefix = ( "" + ( StatCollector . translateToLocal ( "poorores.prefix" ) ) ) . trim ( ) ; <START_BUG> return prefix . replaceFirst ( "ORENAME" , new ItemStack ( getPoorOre ( ) . getBaseBlock ( ) , 1 , getPoorOre ( ) . getMeta ( ) ) . getDisplayName ( ) ) ; <END_BUG> } public PoorOre getPoorOre ( ) { } public void setPoorOre ( PoorOre poorOre ) { } }

Fix:
return prefix . replaceFirst ( "ORENAME" , new ItemStack ( getPoorOre ( ) . getBaseBlock ( ) , 1 , getPoorOre ( ) . getBaseBlockMeta ( ) ) . getDisplayName ( ) ) ;
Buggy code:
public class CategoricalValidator implements Validator < String > { private edu . arizona . biosemantics . matrixreview . client . common . SetValueValidator . CategoricalValidator validator ; public CategoricalValidator ( Set < String > states ) { } @ Override public List < EditorError > validate ( Editor < String > editor , String value ) { List < EditorError > result = new LinkedList < EditorError > ( ) ; ValidationResult validationResult = validator . validate ( value ) ; <START_BUG> if ( validationResult . isValid ( ) ) { <END_BUG> result . add ( new com . sencha . gxt . widget . core . client . form . error . DefaultEditorError ( editor , validationResult . getReason ( ) , value ) ) ; } return result ; } }

Fix:
if ( ! ( validationResult . isValid ( ) ) ) {
Buggy code:
public class Button extends Control { String text ; Image image ; boolean grayed ; static final int EXTRA_HEIGHT = 2 ; static final int EXTRA_WIDTH = 6 ; static final int IMAGE_GAP = 2 ; public Button ( Composite parent , int style ) { } int accessibilityAttributeValue ( int id , int sel , int arg0 ) { NSString nsAttributeName = new NSString ( arg0 ) ; <START_BUG> if ( ( accessible ) != null ) { <END_BUG> id returnObject = accessible . internal_accessibilityAttributeValue ( nsAttributeName , CHILDID_SELF ) ; if ( returnObject != null ) return returnObject . id ; } if ( ( nsAttributeName . isEqualToString ( NSAccessibilityRoleAttribute ) ) || ( nsAttributeName . isEqualToString ( NSAccessibilityRoleDescriptionAttribute ) ) ) { NSString role = null ; if ( ( ( style ) & ( SWT . RADIO ) ) != 0 ) { role = OS . NSAccessibilityRadioButtonRole ; } else if ( ( ( style ) & ( SWT . ARROW ) ) != 0 ) { role = OS . NSAccessibilityButtonRole ; } if ( role != null ) { if ( nsAttributeName . isEqualToString ( NSAccessibilityRoleAttribute ) ) return role . id ; else { return OS . NSAccessibilityRoleDescription ( role . id , 0 ) ; } } } return super . accessibilityAttributeValue ( id , sel , arg0 ) ; } public void addSelectionListener ( SelectionListener listener ) { } NSSize cellSize ( int id , int sel ) { } static int checkStyle ( int style ) { } void click ( ) { } public Point computeSize ( int wHint , int hHint , boolean changed ) { } NSAttributedString createString ( ) { } void createHandle ( ) { } void createWidget ( ) { } NSFont defaultNSFont ( ) { } void deregister ( ) { } boolean dragDetect ( int x , int y , boolean filter , boolean [ ] consume ) { } void drawImageWithFrameInView ( int id , int sel , int image , NSRect rect , int view ) { } void drawInteriorWithFrame_inView ( int id , int sel , NSRect cellRect , int viewid ) { } void drawWidget ( int id , NSGraphicsContext context , NSRect rect ) { } public int getAlignment ( ) { } public boolean getGrayed ( ) { } public Image getImage ( ) { } String getNameText ( ) { } public boolean getSelection ( ) { } public String getText ( ) { } boolean isDescribedByLabel ( ) { } int nextState ( int id , int sel ) { } void register ( ) { } void releaseWidget ( ) { } public void removeSelectionListener ( SelectionListener listener ) { } void selectRadio ( ) { } void sendSelection ( ) { } public void setAlignment ( int alignment ) { } void _setAlignment ( int alignment ) { } void setBackgroundColor ( NSColor nsColor ) { } void setBackgroundImage ( NSImage image ) { } void setFont ( NSFont font ) { } void setForeground ( float [ ] color ) { } public void setGrayed ( boolean grayed ) { } public void setImage ( Image image ) { } boolean setRadioSelection ( boolean value ) { } public void setSelection ( boolean selected ) { } public void setText ( String string ) { } NSRect titleRectForBounds ( int id , int sel , NSRect cellFrame ) { } int traversalCode ( int key , NSEvent theEvent ) { } void updateAlignment ( ) { } }

Fix:
if ( ( id == ( view . id ) ) && ( ( accessible ) != null ) ) {
Buggy code:
public class Player extends BetterActor { Force force = new Force ( ) ; final double pi = Math . PI ; public void act ( ) { } public Player ( ) { } public void checkKeys ( ) { double height = ( getHeight ( ) ) // 2 ; Actor platform = getOneObjectAtOffset ( 0 , ( ( int ) ( height ) ) , Platform . class ) ; if ( Greenfoot . isKeyDown ( "Left" ) ) move ( ( - 5 ) ) ; if ( Greenfoot . isKeyDown ( "Right" ) ) move ( 5 ) ; <START_BUG> if ( ( Greenfoot . isKeyDown ( "Up" ) ) && ( ( ( getY ( ) ) >= ( ( getWorld ( ) . getHeight ( ) ) - height ) ) || ( platform != null ) ) ) { <END_BUG> force . addVectorInDirection ( 90 , ( - 15.0 ) ) ; System . out . println ( "Up<seq2seq4repair_space>detected" ) ; } if ( Greenfoot . isKeyDown ( "Down" ) ) { force . setXComp ( 0 ) ; System . out . println ( "Down<seq2seq4repair_space>detected" ) ; } } public double getHeight ( ) { } public int getScore ( ) { } No newline ; at end ; of file ; }

Fix:
if ( ( Greenfoot . isKeyDown ( "Up" ) ) && ( ( ( getY ( ) ) >= ( ( getWorld ( ) . getHeight ( ) ) - height ) ) && ( platform != null ) ) ) {
Buggy code:
final class BcelField extends ResolvedMember { private Field field ; private boolean isAjSynthetic ; private boolean isSynthetic = false ; BcelField ( BcelObjectType declaringType , Field field ) { } private void unpackAttributes ( World world ) { Attribute [ ] attrs = field . getAttributes ( ) ; <START_BUG> List as = BcelAttributes . readAjAttributes ( attrs , getSourceContext ( world ) ) ; <END_BUG> for ( Iterator iter = as . iterator ( ) ; iter . hasNext ( ) ; ) { AjAttribute a = ( ( AjAttribute ) ( iter . next ( ) ) ) ; if ( a instanceof AjAttribute . AjSynthetic ) { isAjSynthetic = true ; } else { throw new org . aspectj . weaver . BCException ( ( "weird<seq2seq4repair_space>field<seq2seq4repair_space>attribute<seq2seq4repair_space>" + a ) ) ; } } isAjSynthetic = false ; for ( int i = ( attrs . length ) - 1 ; i >= 0 ; i -- ) { if ( ( attrs [ i ] ) instanceof Synthetic ) isSynthetic = true ; } } public boolean isAjSynthetic ( ) { } public boolean isSynthetic ( ) { } }

Fix:
List as = BcelAttributes . readAjAttributes ( attrs , getSourceContext ( world ) , world . getMessageHandler ( ) ) ;