nus-yam/ex-repair huggingface dataset:
Buggy code:
public class JMeterTreeListener implements KeyListener , MouseListener , MouseMotionListener , TreeSelectionListener { private static final Logger log = LoggingManager . getLoggerForClass ( ) ; private TreePath currentPath ; private ActionListener actionHandler ; private JMeterTreeModel model ; private JTree tree ; private boolean dragging = false ; private JMeterTreeNode [ ] draggedNodes ; private JLabel dragIcon = new JLabel ( JMeterUtils . getImage ( "leafnode.gif" ) ) ; public JMeterTreeListener ( JMeterTreeModel model ) { } public JMeterTreeListener ( ) { } public void setModel ( JMeterTreeModel m ) { } public void setActionHandler ( ActionListener ah ) { } public void setJTree ( JTree tree ) { } public void setEndWindow ( Container window ) { } public JTree getJTree ( ) { } public JMeterTreeNode getCurrentNode ( ) { } public JMeterTreeNode [ ] getSelectedNodes ( ) { } public TreePath removedSelectedNode ( ) { } public void valueChanged ( TreeSelectionEvent e ) { } public void mouseClicked ( MouseEvent ev ) { } public void mouseReleased ( MouseEvent e ) { } public JMeterTreeNode [ ] getDraggedNodes ( ) { } private boolean isValidDragAction ( JMeterTreeNode [ ] source , JMeterTreeNode dest ) { } public void mouseEntered ( MouseEvent e ) { } private void changeSelectionIfDragging ( MouseEvent e ) { } private boolean contains ( Object [ ] container , Object item ) { } public void mousePressed ( MouseEvent e ) { } public void mouseDragged ( MouseEvent e ) { } public void mouseMoved ( MouseEvent e ) { } public void mouseExited ( MouseEvent ev ) { } public void keyPressed ( KeyEvent e ) { } public void keyReleased ( KeyEvent e ) { } public void keyTyped ( KeyEvent e ) { } private boolean isRightClick ( MouseEvent e ) { <START_BUG> return ( ( ( MouseEvent . BUTTON2_MASK ) & ( e . getModifiers ( ) ) ) > 0 ) || ( ( MouseEvent . BUTTON3_MASK ) == ( e . getModifiers ( ) ) ) ; <END_BUG> } private void displayPopUp ( MouseEvent e ) { } private void displayPopUp ( MouseEvent e , JPopupMenu popup ) { } }

Fix:
return ( ( e . isPopupTrigger ( ) ) || ( ( ( MouseEvent . BUTTON2_MASK ) & ( e . getModifiers ( ) ) ) > 0 ) ) || ( ( MouseEvent . BUTTON3_MASK ) == ( e . getModifiers ( ) ) ) ;
Buggy code:
public class MailFrameView extends AbstractFrameView { public static final String FOLDERINFOPANEL = "folderinfopanel" ; public JSplitPane mainSplitPane ; public JSplitPane rightSplitPane ; private FolderInfoPanel folderInfoPanel ; public ResourceBundle guiLabels ; private JPanel tablePanel ; FilterToolbar filterToolbar ; HeaderView header ; public MailFrameView ( AbstractFrameController frameController ) { } public void setFolderInfoPanel ( FolderInfoPanel f ) { } public void init ( TreeView tree , TableView table , FilterToolbar filterToolbar , MessageView message , StatusBar statusBar ) { } public void setToolBar ( ToolBar toolBar ) { } public void showFilterToolbar ( ) { } public void hideFilterToolbar ( ) { } public void saveWindowPosition ( ) { } protected Menu createMenu ( AbstractFrameController controller ) { <START_BUG> Menu menu = new org . columba . mail . gui . menu . MailMenu ( "org//columba//core//action//menu.xml" , controller ) ; <END_BUG> return menu ; } protected ToolBar createToolbar ( AbstractFrameController controller ) { } public void showToolbar ( ) { } public void showFolderInfoPanel ( ) { } public boolean isFolderInfoPanelVisible ( ) { } public FilterToolbar getFilterToolbar ( ) { } public FolderInfoPanel getFolderInfoPanel ( ) { } }

Fix:
Menu menu = new org . columba . mail . gui . menu . MailMenu ( "org//columba//core//action//menu.xml" , "org//columba//mail//action//menu.xml" , controller ) ;
Buggy code:
public class ToolItem extends Item { ToolBar parent ; Control control ; String toolTipText ; Image disabledImage ; Image hotImage ; Image disabledImage2 ; int id ; public ToolItem ( ToolBar parent , int style ) { } public ToolItem ( ToolBar parent , int style , int index ) { } public void addSelectionListener ( SelectionListener listener ) { } static int checkStyle ( int style ) { } protected void checkSubclass ( ) { } void click ( boolean dropDown ) { int hwnd = parent . handle ; if ( ( OS . GetKeyState ( VK_LBUTTON ) ) < 0 ) return ; int index = OS . SendMessage ( hwnd , TB_COMMANDTOINDEX , id , 0 ) ; RECT rect = new RECT ( ) ; OS . SendMessage ( hwnd , TB_GETITEMRECT , index , rect ) ; int hotIndex = OS . SendMessage ( hwnd , TB_GETHOTITEM , 0 , 0 ) ; int y = ( rect . top ) + ( ( ( rect . bottom ) - ( rect . top ) ) // 2 ) ; <START_BUG> int lParam = ( ( dropDown ? ( rect . right ) - 1 : rect . left ) & 65535 ) | ( ( y << 16 ) & - 65536 ) ; <END_BUG> parent . ignoreMouse = true ; OS . SendMessage ( hwnd , WM_LBUTTONDOWN , 0 , lParam ) ; OS . SendMessage ( hwnd , WM_LBUTTONUP , 0 , lParam ) ; parent . ignoreMouse = false ; if ( hotIndex != ( - 1 ) ) { OS . SendMessage ( hwnd , TB_SETHOTITEM , hotIndex , 0 ) ; } } void destroyWidget ( ) { } public Rectangle getBounds ( ) { } public Control getControl ( ) { } public Image getDisabledImage ( ) { } public boolean getEnabled ( ) { } public Image getHotImage ( ) { } public ToolBar getParent ( ) { } public boolean getSelection ( ) { } public String getToolTipText ( ) { } public int getWidth ( ) { } public boolean isEnabled ( ) { } void releaseWidget ( ) { } void releaseHandle ( ) { } void releaseImages ( ) { } public void removeSelectionListener ( SelectionListener listener ) { } void resizeControl ( ) { } void selectRadio ( ) { } public void setControl ( Control control ) { } public void setEnabled ( boolean enabled ) { } public void setDisabledImage ( Image image ) { } public void setHotImage ( Image image ) { } public void setImage ( Image image ) { } boolean setRadioSelection ( boolean value ) { } public void setSelection ( boolean selected ) { } public void setText ( String string ) { } public void setToolTipText ( String string ) { } public void setWidth ( int width ) { } void updateImages ( boolean enabled ) { } int widgetStyle ( ) { } LRESULT wmCommandChild ( int wParam , int lParam ) { } }

Fix:
int lParam = OS . MAKELPARAM ( ( dropDown ? ( rect . right ) - 1 : rect . left ) , y ) ;
Buggy code:
public class NavigationDrawerFragment extends Fragment { private static final String STATE_SELECTED_POSITION = "selected_navigation_drawer_position" ; private static final String PREF_USER_LEARNED_DRAWER = "navigation_drawer_learned" ; private NavigationDrawerFragment . NavigationDrawerCallbacks mCallbacks ; private ActionBarDrawerToggle mDrawerToggle ; private DrawerLayout mDrawerLayout ; private ListView mDrawerListView ; private View mFragmentContainerView ; private int mCurrentSelectedPosition = 0 ; private boolean mFromSavedInstanceState ; private boolean mUserLearnedDrawer ; public NavigationDrawerFragment ( ) { } @ Override public void onCreate ( Bundle savedInstanceState ) { } @ Override public void onActivityCreated ( Bundle savedInstanceState ) { } @ Override public View onCreateView ( LayoutInflater inflater , ViewGroup container , Bundle savedInstanceState ) { <START_BUG> mDrawerListView = ( ( ListView ) ( inflater . inflate ( fragment_navigation_drawer2 , container , false ) ) ) ; <END_BUG> mDrawerListView . setOnItemClickListener ( new AdapterView . OnItemClickListener ( ) { @ Override public void onItemClick ( AdapterView < ? > parent , View view , int position , long id ) { selectItem ( position ) ; } } ) ; mDrawerListView . setAdapter ( new android . widget . ArrayAdapter < String > ( getActionBar ( ) . getThemedContext ( ) , layout . simple_list_item_activated_1 , id . text1 , new String [ ] { "Lifestyles" , "Notifications" , "Reminders" , "Section<seq2seq4repair_space>4" , "Section<seq2seq4repair_space>5" } ) ) ; mDrawerListView . setItemChecked ( mCurrentSelectedPosition , true ) ; mDrawerListView . setBackgroundColor ( - 14671840 ) ; return mDrawerListView ; } public boolean isDrawerOpen ( ) { } public void setUp ( int fragmentId , DrawerLayout drawerLayout ) { } private void selectItem ( int position ) { } @ Override public void onAttach ( Activity activity ) { } @ Override public void onDetach ( ) { } @ Override public void onSaveInstanceState ( Bundle outState ) { } @ Override public void onConfigurationChanged ( Configuration newConfig ) { } @ Override public void onCreateOptionsMenu ( Menu menu , MenuInflater inflater ) { } @ Override public boolean onOptionsItemSelected ( MenuItem item ) { } private void showGlobalContextActionBar ( ) { } private ActionBar getActionBar ( ) { } public static interface NavigationDrawerCallbacks { void onNavigationDrawerItemSelected ( int position ) { } } }

Fix:
mDrawerListView = ( ( ListView ) ( inflater . inflate ( fragment_navigation_drawer , container , false ) ) ) ;
Buggy code:
public class MasterElector { private static final Logger LOGGER = LoggerFactory . getLogger ( MasterElector . class ) ; private Application application ; private List < MasterNodeChangeListener > masterNodeChangeListenerList ; private Node master ; public MasterElector ( Application application ) { } public void addMasterNodeChangeListener ( MasterNodeChangeListener masterNodeChangeListener ) { } public Node getMaster ( ) { } public void addNodes ( List < Node > nodes ) { Node newMaster = null ; for ( Node node : nodes ) { if ( newMaster == null ) { newMaster = node ; } else { if ( ( newMaster . getCreateTime ( ) ) > ( node . getCreateTime ( ) ) ) { newMaster = node ; } } } <START_BUG> if ( ( master ) != newMaster ) { <END_BUG> master = newMaster ; notifyListener ( ) ; } } public void addNode ( Node newNode ) { } public void removeNode ( Node removedNode ) { } private void notifyListener ( ) { } }

Fix:
if ( ( ( master ) == null ) || ( ! ( master . equals ( newMaster ) ) ) ) {
Buggy code:
public class CurrentConditions { private String m_conditions = "Unknown" ; private double m_temperature = 0.0 ; private double m_windSpeed = 0.0 ; private String m_windDir = "" ; private int m_humidity = - 1 ; private int m_pickupPeriod = 0 ; private Date m_observationTime = null ; private Date m_refreshAfter = null ; public String getConditions ( ) { } public void setConditions ( String conditions ) { } public double getTemperature ( ) { } public void setTemperature ( double temperature ) { } public double getWindSpeed ( ) { } public void setWindSpeed ( double windSpeed ) { } public String getWindDirAbbreviation ( ) { } public String getWindDir ( ) { } public void setWindDir ( String windDir ) { } public int getHumidity ( ) { } public void setHumidity ( int humidity ) { } public Date getObservationTime ( ) { } public void setObservationTime ( Date observationTime ) { } public int getPickupPeriod ( ) { } public void setPickupPeriod ( int pickupPeriod ) { } private void updateRefreshAfter ( ) { Calendar calendar = Calendar . getInstance ( ) ; calendar . setTime ( m_observationTime ) ; <START_BUG> calendar . add ( Calendar . HOUR_OF_DAY , m_pickupPeriod ) ; <END_BUG> m_refreshAfter = calendar . getTime ( ) ; } public Date getRefreshAfter ( ) { } }

Fix:
calendar . add ( Calendar . MINUTE , m_pickupPeriod ) ;
Buggy code:
public class PojoExtension implements Extension { public static final String SUBSYSTEM_NAME = "pojo" ; public static final String NAMESPACE = "urn:jboss:domain:pojo:1.0" ; private static final PojoExtension . PojoSubsystemParser parser = new PojoExtension . PojoSubsystemParser ( ) ; private static final String RESOURCE_NAME = ( PojoExtension . class . getPackage ( ) . getName ( ) ) + ".LocalDescriptions" ; private static final int MANAGEMENT_API_MAJOR_VERSION = 1 ; private static final int MANAGEMENT_API_MINOR_VERSION = 0 ; private static final int MANAGEMENT_API_MICRO_VERSION = 0 ; static ResourceDescriptionResolver getResourceDescriptionResolver ( final String keyPrefix ) { } @ Override public void initialize ( ExtensionContext context ) { final SubsystemRegistration subsystem = context . registerSubsystem ( PojoExtension . SUBSYSTEM_NAME , PojoExtension . MANAGEMENT_API_MAJOR_VERSION , PojoExtension . MANAGEMENT_API_MINOR_VERSION , PojoExtension . MANAGEMENT_API_MICRO_VERSION ) ; final ManagementResourceRegistration registration = subsystem . registerSubsystemModel ( INSTANCE ) ; <START_BUG> registration . registerOperationHandler ( DESCRIBE , GenericSubsystemDescribeHandler . INSTANCE , GenericSubsystemDescribeHandler . INSTANCE , false , PRIVATE ) ; <END_BUG> subsystem . registerXMLElementWriter ( PojoExtension . parser ) ; } @ Override public void initializeParsers ( ExtensionParsingContext context ) { } static final class PojoSubsystemParser implements XMLStreamConstants , XMLElementReader < List < ModelNode > > , XMLElementWriter < SubsystemMarshallingContext > { @ Override public void writeContent ( final XMLExtendedStreamWriter writer , final SubsystemMarshallingContext context ) throws XMLStreamException { } @ Override public void readElement ( final XMLExtendedStreamReader reader , final List < ModelNode > list ) throws XMLStreamException { } } }

Fix:
registration . registerOperationHandler ( DEFINITION , GenericSubsystemDescribeHandler . INSTANCE ) ;
Buggy code:
public abstract class AbstractNumericValidator extends AbstractNumericFacetValidator { public AbstractNumericValidator ( ) { } public AbstractNumericValidator ( DatatypeValidator base , Hashtable facets , boolean derivedByList , XMLErrorReporter reporter ) { } <START_BUG> public Object validate ( String content , Object state ) throws InvalidDatatypeValueException { <END_BUG> checkContent ( content , state , null , false ) ; return null ; } public Object clone ( ) throws CloneNotSupportedException { } protected void checkContentEnum ( String content , Object state , Vector enumeration ) throws InvalidDatatypeValueException { } protected abstract void checkContent ( String content , Object State ) { } protected void boundsCheck ( Object d ) throws InvalidDatatypeValueException { } }

Fix:
public Object validate ( String content , ValidationContext state ) throws InvalidDatatypeValueException {
Buggy code:
public class ConfigurationManagement extends TestBase { private MDMHttpClient client ; @ BeforeClass ( alwaysRun = true , groups = { Constants . ConfigurationManagement . CONFIGURATION_MANAGEMENT_GROUP } ) public void initTest ( ) throws Exception { } @ Test ( description = "Test<seq2seq4repair_space>save<seq2seq4repair_space>configuration." ) public void testSaveConfiguration ( ) throws Exception { } @ Test ( description = "Test<seq2seq4repair_space>get<seq2seq4repair_space>configuration." , dependsOnMethods = { "testSaveConfiguration" } ) public void testGetConfiguration ( ) throws Exception { MDMResponse response = client . get ( CONFIGURATION_ENDPOINT ) ; Assert . assertEquals ( SC_OK , response . getStatus ( ) ) ; <START_BUG> AssertUtil . jsonPayloadCompare ( PayloadGenerator . getJsonPayload ( CONFIGURATION_RESPONSE_PAYLOAD_FILE_NAME , HTTP_METHOD_GET ) . toString ( ) , response . getBody ( ) , true ) ; <END_BUG> } @ Test ( description = "Test<seq2seq4repair_space>get<seq2seq4repair_space>configuration<seq2seq4repair_space>with<seq2seq4repair_space>erroneous<seq2seq4repair_space>end<seq2seq4repair_space>point." , dependsOnMethods = { "testSaveConfiguration" } ) public void testGetConfigurationWithErroneousEndPoint ( ) throws Exception { } }

Fix:
AssertUtil . jsonPayloadCompare ( PayloadGenerator . getJsonPayload ( CONFIGURATION_RESPONSE_PAYLOAD_FILE_NAME , HTTP_METHOD_GET ) . toString ( ) , response . getBody ( ) , false ) ;
Buggy code:
class SecurityActions { static ModuleClassLoader getModuleClassLoader ( final String moduleSpec ) throws ModuleLoadException { try { return AccessController . doPrivileged ( new PrivilegedExceptionAction < ModuleClassLoader > ( ) { public ModuleClassLoader run ( ) throws ModuleLoadException { <START_BUG> ModuleLoader loader = Module . getCurrentModuleLoader ( ) ; <END_BUG> ModuleIdentifier identifier = ModuleIdentifier . fromString ( moduleSpec ) ; return loader . loadModule ( identifier ) . getClassLoader ( ) ; } } ) ; } catch ( PrivilegedActionException pae ) { throw new ModuleLoadException ( pae ) ; } } static SecurityContext getSecurityContext ( ) { } static Principal getPrincipal ( ) { } static Object getCredential ( ) { } }

Fix:
ModuleLoader loader = Module . getCallerModuleLoader ( ) ;
Buggy code:
@ SuppressWarnings ( "serial" ) public abstract class HttpServletBean extends HttpServlet implements EnvironmentAware , EnvironmentCapable { protected final Log logger = LogFactory . getLog ( getClass ( ) ) ; private final Set < String > requiredProperties = new HashSet < String > ( ) ; private ConfigurableWebEnvironment environment ; protected final void addRequiredProperty ( String property ) { } @ Override public final void init ( ) throws ServletException { if ( logger . isDebugEnabled ( ) ) { logger . debug ( ( ( "Initializing<seq2seq4repair_space>servlet<seq2seq4repair_space>'" + ( getServletName ( ) ) ) + "'" ) ) ; } try { PropertyValues pvs = new HttpServletBean . ServletConfigPropertyValues ( getServletConfig ( ) , this . requiredProperties ) ; BeanWrapper bw = PropertyAccessorFactory . forBeanPropertyAccess ( this ) ; ResourceLoader resourceLoader = new org . springframework . web . context . support . ServletContextResourceLoader ( getServletContext ( ) ) ; <START_BUG> bw . registerCustomEditor ( Resource . class , new org . springframework . core . io . ResourceEditor ( resourceLoader , this . getEnvironment ( ) ) ) ; <END_BUG> initBeanWrapper ( bw ) ; bw . setPropertyValues ( pvs , true ) ; } catch ( BeansException ex ) { logger . error ( ( ( "Failed<seq2seq4repair_space>to<seq2seq4repair_space>set<seq2seq4repair_space>bean<seq2seq4repair_space>properties<seq2seq4repair_space>on<seq2seq4repair_space>servlet<seq2seq4repair_space>'" + ( getServletName ( ) ) ) + "'" ) , ex ) ; throw ex ; } initServletBean ( ) ; if ( logger . isDebugEnabled ( ) ) { logger . debug ( ( ( "Servlet<seq2seq4repair_space>'" + ( getServletName ( ) ) ) + "'<seq2seq4repair_space>configured<seq2seq4repair_space>successfully" ) ) ; } } protected void initBeanWrapper ( BeanWrapper bw ) throws BeansException { } @ Override public final String getServletName ( ) { } @ Override public final ServletContext getServletContext ( ) { } protected void initServletBean ( ) throws ServletException { } public void setEnvironment ( Environment environment ) { } public ConfigurableWebEnvironment getEnvironment ( ) { } protected ConfigurableWebEnvironment createEnvironment ( ) { } private static class ServletConfigPropertyValues extends MutablePropertyValues { public ServletConfigPropertyValues ( ServletConfig config , Set < String > requiredProperties ) throws ServletException { } } }

Fix:
bw . registerCustomEditor ( Resource . class , new org . springframework . core . io . ResourceEditor ( resourceLoader , getEnvironment ( ) ) ) ;
Buggy code:
public class Scenario { private final String id = null ; private final String name = null ; private final String type = null ; private final String description = null ; private final String keyword = null ; private final Step [ ] steps = new Step [ 0 ] ; private final Hook [ ] before = new Hook [ 0 ] ; private final Hook [ ] after = new Hook [ 0 ] ; private final Tag [ ] tags = new Tag [ 0 ] ; private String beforeAttachments ; private String afterAttachments ; private StatusCounter statusCounter ; private Feature feature ; public Step [ ] getSteps ( ) { } public Hook [ ] getBefore ( ) { } public Hook [ ] getAfter ( ) { } public Tag [ ] getTags ( ) { } public String getBeforeAttachments ( ) { } public String getAfterAttachments ( ) { } public Status getStatus ( ) { } public String getId ( ) { } public String getRawName ( ) { } public String getKeyword ( ) { } public String getType ( ) { } public String getName ( ) { } public boolean hasTags ( ) { } public boolean hasSteps ( ) { } public String getTagsList ( ) { } public Feature getFeature ( ) { } @ Override public int hashCode ( ) { } @ Override public boolean equals ( Object obj ) { } public void setMedaData ( Feature feature ) { } private void calculateStatus ( ) { } private void calculateHooks ( Hook [ ] hooks ) { } private String calculateAttachments ( String keyword , Hook [ ] hooks ) { StringBuilder sb = new StringBuilder ( ) ; for ( int i = 0 ; i < ( hooks . length ) ; i ++ ) { String status = hooks [ i ] . getResult ( ) . getStatus ( ) ; sb . append ( "<div<seq2seq4repair_space>class=\"" ) . append ( status ) . append ( "\">" ) ; sb . append ( "<span<seq2seq4repair_space>class=\"step-keyword\">" ) . append ( keyword ) . append ( "<seq2seq4repair_space><//span>" ) ; sb . append ( "<i>" ) . append ( hooks [ i ] . getMatch ( ) . getLocation ( ) ) . append ( "<//i>" ) ; sb . append ( "<span<seq2seq4repair_space>class=\"step-duration\">" ) ; <START_BUG> if ( status != ( MISSING . getName ( ) ) ) { <END_BUG> sb . append ( Util . formatDuration ( hooks [ i ] . getResult ( ) . getDuration ( ) ) ) ; } sb . append ( "<//span>" ) ; sb . append ( Util . formatErrorMessage ( hooks [ i ] . getResult ( ) . getErrorMessage ( ) , hooks [ i ] . getResult ( ) . hashCode ( ) ) ) ; sb . append ( "<//div>" ) ; sb . append ( hooks [ i ] . getAttachments ( ) ) ; } return sb . toString ( ) ; } }

Fix:
if ( Status . MISSING . getName ( ) . equals ( status ) ) {
Buggy code:
public class StackExchangeChat implements ChatInterface { private static final int MINIMUM_MESSAGE_LENGTH = 12 ; private static final Logger LOGGER = Logger . getLogger ( StackExchangeChat . class . getName ( ) ) ; private static final int MESSAGE_COUNT = 5 ; private static final Gson GSON = new Gson ( ) ; private final Map < SeChatDescriptor , HtmlPage > chatMap = new TreeMap < > ( ) ; private boolean loggedIn = false ; private final WebClient webClient ; private final Set < ChatWorker > subscribers = new HashSet < > ( ) ; private final Set < Long > handledMessages = new HashSet < > ( ) ; private final ScheduledThreadPoolExecutor sender = new ScheduledThreadPoolExecutor ( 1 ) ; private final Random rnd ; public StackExchangeChat ( ) { } @ Override public boolean login ( ProviderDescriptor descriptor , CredentialsProvider credentials ) { } private WebResponse submitLoginForm ( HtmlForm loginForm ) { } private HtmlPage getLoginPage ( ProviderDescriptor descriptor ) { } private void logLoginMessage ( final String site , final String email , WebResponse response ) { } private HtmlForm extractLoginForm ( final String email , final String password , HtmlPage loginPage ) { } public boolean isLoggedIn ( ) { } @ Override public boolean joinChat ( ChatDescriptor descriptor ) { } @ Override public boolean leaveChat ( ChatDescriptor descriptor ) { } @ Override public boolean sendMessage ( ChatDescriptor descriptor , String message ) { } private String handleMessageOversize ( final SeChatDescriptor descriptor , String message ) { } private boolean sendMessage ( String restRootUrl , String fkey , String message ) { } @ Override public void broadcast ( final String message ) { } @ Override public synchronized void queryMessages ( ) { } private void queryAndHandleRoomEvents ( final SeChatDescriptor descriptor , final String fkey ) { JsonMessages messages = queryMessages ( descriptor , fkey ) ; if ( null == messages ) { return ; } <START_BUG> messages . setSite ( SESite . fromUrl ( descriptor . getProvider ( ) . getDescription ( ) . toString ( ) ) ) ; <END_BUG> handleChatEvents ( messages ) ; } private JsonMessages queryMessages ( final SeChatDescriptor descriptor , final String fkey ) { } private void handleInitialEvents ( SeChatDescriptor descriptor , String fkey ) { } private String fetchMessageJson ( final URL roomUrl , final String fkey ) { } private String fetchJson ( final URL restUrl , final ArrayList < NameValuePair > params ) { } private void handleChatEvents ( final JsonMessages events ) { } @ Override public void subscribe ( final ChatWorker subscriber ) { } @ Override public void unSubscribe ( final ChatWorker subscriber ) { } @ Override public void close ( ) throws Exception { } @ Override public Collection < ChatWorker > getSubscriptions ( ) { } }

Fix:
messages . setSite ( ( ( SESite ) ( descriptor . getProvider ( ) ) ) ) ;
Buggy code:
public class DefaultParentAware < P extends Node < ? > > implements ParentAware < P > { private final transient List < P > parents = new ArrayList < > ( ) ; private final transient List < P > parentsUnmodifiable = Collections . unmodifiableList ( parents ) ; @ Override public List < P > getParents ( ) { } @ Override public P getSingleParent ( ) { } @ Override public int getParentCount ( ) { } @ SuppressWarnings ( "unchecked" ) @ Override public void addParent ( Node < ? > parent ) { if ( parent != null ) { Class < ? > allowedParentClass = TypeResolver . resolveRawArgument ( ParentAware . class , getClass ( ) ) ; boolean allowedParent = allowedParentClass . isAssignableFrom ( parent . getClass ( ) ) ; <START_BUG> if ( allowedParent ) { <END_BUG> parents . add ( ( ( P ) ( parent ) ) ) ; } else { throw new IllegalParentTypeException ( this , parent , ( ( ( ( "Nodes<seq2seq4repair_space>of<seq2seq4repair_space>type<seq2seq4repair_space>'" + ( parent . getClass ( ) . getName ( ) ) ) + "'<seq2seq4repair_space>are<seq2seq4repair_space>not<seq2seq4repair_space>allowed<seq2seq4repair_space>to<seq2seq4repair_space>reference<seq2seq4repair_space>parent-aware<seq2seq4repair_space>objects<seq2seq4repair_space>of<seq2seq4repair_space>type<seq2seq4repair_space>'" ) + ( getClass ( ) . getName ( ) ) ) + "'" ) ) ; } } } @ Override public void removeParent ( Node < ? > parent ) { } }

Fix:
if ( allowedParent || ( allowedParentClass == ( Unknown . class ) ) ) {
Buggy code:
@ Component @ Transactional ( readOnly = true ) public class DataHarvestService { @ Autowired private PageurlinfoService pageurlinfoService ; @ Autowired private PagedatainfoService pagedatainfoService ; @ Autowired private JdbcTemplate jdbcTemplate ; Pagedatainfo listPagedatainfo ; Message logmsg = new Message ( ) ; public List getPiechartData ( ) { } public List getPiechartDate ( String url ) { } public boolean selectedsave ( Pageurlinfo pageurlinfo ) throws MalformedURLException { Document doc ; listPagedatainfo = null ; logmsg . setMessage ( null ) ; HtmlPage page = HarvestUtil . getPage ( pageurlinfo . getUrl ( ) ) ; doc = Jsoup . parse ( page . asXml ( ) ) ; String selectedelement = ( ( ( ( ( pageurlinfo . getElement ( ) ) + "[" ) + ( pageurlinfo . getAttribute ( ) ) ) + "=" ) + ( pageurlinfo . getValue ( ) ) ) + "]" ; if ( pageurlinfo . getAttribute ( ) . equals ( "id" ) ) { selectedelement = ( ( pageurlinfo . getElement ( ) ) + "#" ) + ( pageurlinfo . getValue ( ) ) ; } else if ( pageurlinfo . getAttribute ( ) . equals ( "class" ) ) { selectedelement = ( ( pageurlinfo . getElement ( ) ) + "." ) + ( pageurlinfo . getValue ( ) ) ; } Elements elements = doc . select ( selectedelement ) ; <START_BUG> if ( ( ( pageurlinfo . getStartTag ( ) ) != null ) && ( ( pageurlinfo . getEndTag ( ) ) != null ) ) { <END_BUG> String title = StringUtils . substringBetween ( elements . html ( ) . toString ( ) , pageurlinfo . getStartTag ( ) , pageurlinfo . getEndTag ( ) ) ; if ( ( title != null ) && ( title != "" ) ) { doc = Jsoup . parse ( title ) ; elements = doc . select ( "body" ) ; } } if ( ! ( pageurlinfo . getElement ( ) . equals ( "table" ) ) ) { Elements tableElements = elements . select ( "table" ) ; if ( ! ( tableElements . isEmpty ( ) ) ) { parseElements ( tableElements , pageurlinfo ) ; elements . select ( "table" ) . remove ( ) ; } } parseElements ( elements , pageurlinfo ) ; return true ; } private void parseElements ( Elements elements , Pageurlinfo pageurlinfo ) throws MalformedURLException { } private void saveData ( Element element , Pageurlinfo pageurlinfo , String rowGroupKey , String tableGroupKey ) throws MalformedURLException { } public boolean basicsave ( Pageurlinfo pageurlinfo ) { } public void logProgress ( HttpServletResponse response ) throws IOException { } }

Fix:
if ( ( ( ( pageurlinfo . getStartTag ( ) ) != null ) && ( ( pageurlinfo . getEndTag ( ) ) != null ) ) && ( ( ! ( pageurlinfo . getStartTag ( ) . isEmpty ( ) ) ) && ( ! ( pageurlinfo . getEndTag ( ) . isEmpty ( ) ) ) ) ) {
Buggy code:
public class CompactionsTest extends CleanupHelper { @ Test public void testCompactions ( ) throws IOException , InterruptedException , ExecutionException { Table table = Table . open ( "Keyspace1" ) ; ColumnFamilyStore store = table . getColumnFamilyStore ( "Standard1" ) ; final int ROWS_PER_SSTABLE = 10 ; Set < String > inserted = new HashSet < String > ( ) ; for ( int j = 0 ; j < ( ( ( SSTableReader . indexInterval ( ) ) * 3 ) // ROWS_PER_SSTABLE ) ; j ++ ) { for ( int i = 0 ; i < ROWS_PER_SSTABLE ; i ++ ) { String key = String . valueOf ( ( i % 2 ) ) ; RowMutation rm = new RowMutation ( "Keyspace1" , key ) ; rm . add ( new QueryPath ( "Standard1" , null , String . valueOf ( ( i // 2 ) ) . getBytes ( ) ) , new byte [ 0 ] , ( ( j * ROWS_PER_SSTABLE ) + i ) ) ; rm . apply ( ) ; inserted . add ( key ) ; } store . forceBlockingFlush ( ) ; Assert . assertEquals ( table . getColumnFamilyStore ( "Standard1" ) . getKeyRange ( "" , "" , 10000 ) . keys . size ( ) , inserted . size ( ) ) ; } while ( true ) { <START_BUG> Future < Integer > ft = MinorCompactionManager . instance ( ) . submit ( store ) ; <END_BUG> if ( ( ft . get ( ) ) == 0 ) break ; } if ( ( store . getSSTables ( ) . size ( ) ) > 1 ) { store . doCompaction ( 2 , store . getSSTables ( ) . size ( ) ) ; } Assert . assertEquals ( table . getColumnFamilyStore ( "Standard1" ) . getKeyRange ( "" , "" , 10000 ) . keys . size ( ) , inserted . size ( ) ) ; } }

Fix:
Future < Integer > ft = CompactionManager . instance ( ) . submit ( store ) ;
Buggy code:
class PackageFragmentRootInfo extends OpenableElementInfo { protected int fRootKind = IPackageFragmentRoot . K_SOURCE ; protected Object [ ] fNonJavaResources ; public PackageFragmentRootInfo ( ) { } static Object [ ] computeFolderNonJavaResources ( JavaProject project , IContainer folder , char [ ] [ ] exclusionPatterns ) throws JavaModelException { } private Object [ ] computeNonJavaResources ( IJavaProject project , IResource underlyingResource , PackageFragmentRoot handle ) { Object [ ] nonJavaResources = JavaElementInfo . NO_NON_JAVA_RESOURCES ; try { if ( ( ( underlyingResource . getType ( ) ) == ( IResource . FOLDER ) ) || ( ( underlyingResource . getType ( ) ) == ( IResource . PROJECT ) ) ) { <START_BUG> nonJavaResources = PackageFragmentRootInfo . computeFolderNonJavaResources ( ( ( JavaProject ) ( project ) ) , ( ( IContainer ) ( underlyingResource ) ) , handle . getExclusionPatterns ( ) ) ; <END_BUG> } } catch ( JavaModelException e ) { } return nonJavaResources ; } synchronized Object [ ] getNonJavaResources ( IJavaProject project , IResource underlyingResource , PackageFragmentRoot handle ) { } public int getRootKind ( ) { } synchronized void setNonJavaResources ( Object [ ] resources ) { } protected void setRootKind ( int newRootKind ) { } }

Fix:
nonJavaResources = PackageFragmentRootInfo . computeFolderNonJavaResources ( ( ( JavaProject ) ( project ) ) , ( ( IContainer ) ( underlyingResource ) ) , handle . fullExclusionPatternChars ( ) ) ;
Buggy code:
public class XmlLogger implements BuildListener { private static final DocumentBuilder builder = XmlLogger . getDocumentBuilder ( ) ; private static DocumentBuilder getDocumentBuilder ( ) { } private static final String BUILD_TAG = "build" ; private static final String TARGET_TAG = "target" ; private static final String TASK_TAG = "task" ; private static final String MESSAGE_TAG = "message" ; private static final String NAME_ATTR = "name" ; private static final String TIME_ATTR = "time" ; private static final String PRIORITY_ATTR = "priority" ; private static final String LOCATION_ATTR = "location" ; private static final String ERROR_ATTR = "error" ; private Document doc ; private Hashtable tasks = new Hashtable ( ) ; private Hashtable targets = new Hashtable ( ) ; private Hashtable threadStacks = new Hashtable ( ) ; private XmlLogger . TimedElement buildElement = null ; private static class TimedElement { long startTime ; Element element ; } public XmlLogger ( ) { } public void buildStarted ( BuildEvent event ) { } public void buildFinished ( BuildEvent event ) { long totalTime = ( System . currentTimeMillis ( ) ) - ( buildElement . startTime ) ; buildElement . element . setAttribute ( XmlLogger . TIME_ATTR , DefaultLogger . formatTime ( totalTime ) ) ; if ( ( event . getException ( ) ) != null ) { buildElement . element . setAttribute ( XmlLogger . ERROR_ATTR , event . getException ( ) . toString ( ) ) ; } try { String outFilename = event . getProject ( ) . getProperty ( "XmlLogger.file" ) ; if ( outFilename == null ) { outFilename = "log.xml" ; } Writer out = new OutputStreamWriter ( new FileOutputStream ( outFilename ) , "UTF8" ) ; out . write ( "<?xml<seq2seq4repair_space>version=\"1.0\"<seq2seq4repair_space>encoding=\"UTF-8\"<seq2seq4repair_space>?>\n" ) ; <START_BUG> out . write ( "<?xml:stylesheet<seq2seq4repair_space>type=\"text//xsl\"<seq2seq4repair_space>href=\"log.xsl\"?>\n\n" ) ; <END_BUG> new DOMElementWriter ( ) . write ( buildElement . element , out , 0 , "\t" ) ; out . flush ( ) ; out . close ( ) ; } catch ( IOException exc ) { throw new BuildException ( "Unable<seq2seq4repair_space>to<seq2seq4repair_space>close<seq2seq4repair_space>log<seq2seq4repair_space>file" , exc ) ; } buildElement = null ; } private Stack getStack ( ) { } public void targetStarted ( BuildEvent event ) { } public void targetFinished ( BuildEvent event ) { } public void taskStarted ( BuildEvent event ) { } public void taskFinished ( BuildEvent event ) { } public void messageLogged ( BuildEvent event ) { } }

Fix:
out . write ( "<?xml-stylesheet<seq2seq4repair_space>type=\"text//xsl\"<seq2seq4repair_space>href=\"log.xsl\"?>\n\n" ) ;
Buggy code:
public class UserParameterModifierGui extends AbstractPreProcessorGui { private JTextField fileNameField ; public UserParameterModifierGui ( ) { } public TestElement createTestElement ( ) { } public void modifyTestElement ( TestElement mod ) { } public void updateGui ( ) { } public String getStaticLabel ( ) { <START_BUG> return JMeterUtils . getResString ( "HTTP<seq2seq4repair_space>User<seq2seq4repair_space>Parameter<seq2seq4repair_space>Modifier" ) ; <END_BUG> } public void configure ( TestElement el ) { } private void init ( ) { } private JPanel getFileLocator ( ) { } public Dimension getPreferredSize ( ) { } }

Fix:
return JMeterUtils . getResString ( "http_user_parameter_modifier" ) ;
Buggy code:
public class Main extends JavaPlugin { public List < UUID > players = new ArrayList < UUID > ( ) ; public List < UUID > sadplayers = new ArrayList < UUID > ( ) ; public List < UUID > normalplayers = new ArrayList < UUID > ( ) ; public List < UUID > happyplayers = new ArrayList < UUID > ( ) ; @ Override public void onEnable ( ) { getCommand ( "cloud" ) . setExecutor ( new Cloud ( this ) ) ; new org . bukkit . scheduler . BukkitRunnable ( ) { public void run ( ) { for ( UUID uuid : sadplayers ) { org . bukkit . entity . Player player = org . bukkit . Bukkit . getPlayer ( uuid ) ; if ( player != null ) { org . bukkit . Location location = player . getLocation ( ) ; ParticleEffect . CLOUD . display ( 0.4F , 0.5F , 0.4F , 0 , 50 , location . clone ( ) . add ( 0 , 6 , 0 ) , 20 ) ; ParticleEffect . WATER_DROP . display ( 0.4F , 0.5F , 0.4F , 0 , 100 , location . clone ( ) . add ( 0 , 5 , 0 ) , 20 ) ; } } } } . runTaskTimer ( this , 2 , 2 ) ; new org . bukkit . scheduler . BukkitRunnable ( ) { public void run ( ) { for ( UUID uuid : normalplayers ) { org . bukkit . entity . Player player = org . bukkit . Bukkit . getPlayer ( uuid ) ; if ( player != null ) { org . bukkit . Location location = player . getLocation ( ) ; <START_BUG> ParticleEffect . CLOUD . display ( 0.4F , 0.5F , 0.4F , 0 , 50 , location . clone ( ) . add ( 0 , 6 , 0 ) , 20 ) ; <END_BUG> ParticleEffect . WATER_DROP . display ( 0.4F , 0.5F , 0.4F , 0 , 100 , location . clone ( ) . add ( 0 , 5 , 0 ) , 20 ) ; } } } } . runTaskTimer ( this , 2 , 2 ) ; new org . bukkit . scheduler . BukkitRunnable ( ) { public void run ( ) { for ( UUID uuid : happyplayers ) { org . bukkit . entity . Player player = org . bukkit . Bukkit . getPlayer ( uuid ) ; if ( player != null ) { org . bukkit . Location location = player . getLocation ( ) ; ParticleEffect . CLOUD . display ( 0.4F , 0.5F , 0.4F , 0 , 50 , location . clone ( ) . add ( 0 , 6 , 0 ) , 20 ) ; ParticleEffect . FIREWORKS_SPARK . display ( 0.2F , 0.5F , 0.2F , 0 , 30 , location . clone ( ) . add ( 0 , 5 , 0 ) , 20 ) ; } } } } . runTaskTimer ( this , 2 , 2 ) ; } }

Fix:
ParticleEffect . FIREWORKS_SPARK . display ( 0.4F , 0.5F , 0.4F , 0 , 50 , location . clone ( ) . add ( 0 , 6 , 0 ) , 20 ) ;
Buggy code:
public class CommitLogSegment { private static final Logger logger = LoggerFactory . getLogger ( CommitLogSegment . class ) ; private final BufferedRandomAccessFile logWriter ; private final CommitLogHeader header ; public CommitLogSegment ( ) { } public static boolean possibleCommitLogFile ( String filename ) { } public void writeHeader ( ) throws IOException { } private static BufferedRandomAccessFile createWriter ( String file ) throws IOException { } public CommitLogSegment . CommitLogContext write ( RowMutation rowMutation , Object serializedRow ) throws IOException { long currentPosition = - 1L ; try { currentPosition = logWriter . getFilePointer ( ) ; CommitLogSegment . CommitLogContext cLogCtx = new CommitLogSegment . CommitLogContext ( currentPosition ) ; for ( ColumnFamily columnFamily : rowMutation . getColumnFamilies ( ) ) { CFMetaData cfm = DatabaseDescriptor . getCFMetaData ( columnFamily . id ( ) ) ; if ( cfm == null ) { CommitLogSegment . logger . error ( ( "Attempted<seq2seq4repair_space>to<seq2seq4repair_space>write<seq2seq4repair_space>commit<seq2seq4repair_space>log<seq2seq4repair_space>entry<seq2seq4repair_space>for<seq2seq4repair_space>unrecognized<seq2seq4repair_space>column<seq2seq4repair_space>family:<seq2seq4repair_space>" + ( columnFamily . id ( ) ) ) ) ; } else { <START_BUG> int id = cfm . cfId ; <END_BUG> if ( ! ( header . isDirty ( id ) ) ) { header . turnOn ( id , logWriter . getFilePointer ( ) ) ; writeHeader ( ) ; } } } byte [ ] bytes ; Checksum checksum = new CRC32 ( ) ; if ( serializedRow instanceof DataOutputBuffer ) { bytes = ( ( DataOutputBuffer ) ( serializedRow ) ) . getData ( ) ; } else { assert serializedRow instanceof byte [ ] ; bytes = ( ( byte [ ] ) ( serializedRow ) ) ; } checksum . update ( bytes . length ) ; logWriter . writeInt ( bytes . length ) ; logWriter . writeLong ( checksum . getValue ( ) ) ; logWriter . write ( bytes ) ; checksum . update ( bytes , 0 , bytes . length ) ; logWriter . writeLong ( checksum . getValue ( ) ) ; return cLogCtx ; } catch ( IOException e ) { if ( currentPosition != ( - 1 ) ) logWriter . seek ( currentPosition ) ; throw e ; } } public void sync ( ) throws IOException { } public CommitLogSegment . CommitLogContext getContext ( ) { } public CommitLogHeader getHeader ( ) { } public String getPath ( ) { } public String getHeaderPath ( ) { } public long length ( ) { } public void close ( ) { } @ Override public String toString ( ) { } public class CommitLogContext { public final long position ; public CommitLogContext ( long position ) { } public CommitLogSegment getSegment ( ) { } @ Override public String toString ( ) { } } }

Fix:
Integer id = cfm . cfId ;
Buggy code:
public class MarkupCache { private static final Log log = LogFactory . getLog ( MarkupCache . class ) ; private final Map markupCache = new HashMap ( ) ; private final Watcher afterLoadListeners = new Watcher ( ) ; private final Application application ; public MarkupCache ( final Application application ) { } public final MarkupStream getMarkupStream ( final MarkupContainer container ) { } public final MarkupStream getMarkupStream ( final MarkupContainer container , final boolean throwException ) { if ( container == null ) { throw new IllegalArgumentException ( "Parameter<seq2seq4repair_space>'container'<seq2seq4repair_space>must<seq2seq4repair_space>not<seq2seq4repair_space>be<seq2seq4repair_space>'null'." ) ; } Markup markup = getMarkup ( new ContainerInfo ( container ) , container . getClass ( ) ) ; if ( markup != ( Markup . NO_MARKUP ) ) { return new MarkupStream ( markup ) ; } if ( throwException == true ) { <START_BUG> throw new MarkupNotFoundException ( ( ( "Markup<seq2seq4repair_space>not<seq2seq4repair_space>found.<seq2seq4repair_space>Component<seq2seq4repair_space>class:<seq2seq4repair_space>" + ( container . getClass ( ) . getName ( ) ) ) + "<seq2seq4repair_space>Enable<seq2seq4repair_space>debug<seq2seq4repair_space>messages<seq2seq4repair_space>for<seq2seq4repair_space>wicket.util.resource.Resource<seq2seq4repair_space>to<seq2seq4repair_space>get<seq2seq4repair_space>a<seq2seq4repair_space>list<seq2seq4repair_space>of<seq2seq4repair_space>all<seq2seq4repair_space>filenames<seq2seq4repair_space>tried." ) ) ; <END_BUG> } return null ; } public final boolean hasAssociatedMarkup ( final MarkupContainer container ) { } private MarkupResourceStream newMarkupResourceStream ( final Class containerClass , final ContainerInfo containerInfo ) { } private final Markup getMarkup ( final ContainerInfo containerInfo , final Class clazz ) { } private final Markup loadMarkup ( final String key , final MarkupResourceStream markupResourceStream ) { } private final Markup loadMarkupAndWatchForChanges ( final String key , final MarkupResourceStream markupResourceStream ) { } private final String markupKey ( final ContainerInfo containerInfo , final Class clazz ) { } public void clear ( ) { } private Markup checkForMarkupInheritance ( final String key , final Markup markup ) { } private int requiresBaseMarkup ( final Markup markup ) { } }

Fix:
throw new MarkupNotFoundException ( ( ( "Markup<seq2seq4repair_space>not<seq2seq4repair_space>found.<seq2seq4repair_space>Component<seq2seq4repair_space>class:<seq2seq4repair_space>" + ( container . getClass ( ) . getName ( ) ) ) + "<seq2seq4repair_space>Enable<seq2seq4repair_space>debug<seq2seq4repair_space>messages<seq2seq4repair_space>for<seq2seq4repair_space>wicket.util.resource<seq2seq4repair_space>to<seq2seq4repair_space>get<seq2seq4repair_space>a<seq2seq4repair_space>list<seq2seq4repair_space>of<seq2seq4repair_space>all<seq2seq4repair_space>filenames<seq2seq4repair_space>tried" ) ) ;
Buggy code:
public final class MarkupParserTest extends WicketTestCase { private static final Logger log = LoggerFactory . getLogger ( MarkupParserTest . class ) ; public MarkupParserTest ( String name ) { } public final void testTagParsing ( ) throws Exception { } public final void test ( ) throws Exception { } public final void testXhtmlDocument ( ) throws Exception { } private MarkupResourceStream newMarkupResourceStream ( final IResourceStreamLocator locator , final Class c , final String style , final String variation , final Locale locale , final String extension ) { <START_BUG> IResourceStream resource = locator . locate ( c , c . getName ( ) . replace ( '.' , '//' ) , style , variation , locale , extension ) ; <END_BUG> MarkupResourceStream res = new MarkupResourceStream ( resource , null , null ) ; return res ; } public final void testFileDocument ( ) throws IOException , ParseException , ResourceStreamNotFoundException { } public final void testWicketTag ( ) throws IOException , ParseException , ResourceStreamNotFoundException { } public final void testDefaultWicketTag ( ) throws IOException , ParseException , ResourceStreamNotFoundException { } public final void testScript ( ) throws IOException , ParseException , ResourceStreamNotFoundException { } public final void testBalancing ( ) throws IOException , ResourceStreamNotFoundException { } }

Fix:
IResourceStream resource = locator . locate ( c , c . getName ( ) . replace ( '.' , '//' ) , style , variation , locale , extension , false ) ;
Buggy code:
class FileStatusHandler { private static Logger logger = LoggerFactory . getLogger ( FileStatusHandler . class ) ; public void onStatusChange ( InetAddress host , PendingFile pendingFile , FileStatus streamStatus ) throws IOException { if ( ( Action . STREAM ) == ( streamStatus . getAction ( ) ) ) { FileStatusHandler . logger . warn ( ( ( ( ( "Streaming<seq2seq4repair_space>of<seq2seq4repair_space>file<seq2seq4repair_space>" + pendingFile ) + "<seq2seq4repair_space>from<seq2seq4repair_space>" ) + host ) + "<seq2seq4repair_space>failed:<seq2seq4repair_space>requesting<seq2seq4repair_space>a<seq2seq4repair_space>retry." ) ) ; instance . sendOneWay ( streamStatus . makeStreamStatusMessage ( ) , host ) ; return ; } assert ( Action . DELETE ) == ( streamStatus . getAction ( ) ) : "Unknown<seq2seq4repair_space>stream<seq2seq4repair_space>action:<seq2seq4repair_space>" + ( streamStatus . getAction ( ) ) ; if ( pendingFile . getFilename ( ) . endsWith ( "-Data.db" ) ) { String tableName = pendingFile . getDescriptor ( ) . ksname ; File file = new File ( pendingFile . getFilename ( ) ) ; String fileName = file . getName ( ) ; String [ ] temp = fileName . split ( "-" ) ; try { <START_BUG> SSTableReader sstable = SSTableWriter . renameAndOpen ( pendingFile . getFilename ( ) ) ; <END_BUG> Table . open ( tableName ) . getColumnFamilyStore ( temp [ 0 ] ) . addSSTable ( sstable ) ; FileStatusHandler . logger . info ( ( "Streaming<seq2seq4repair_space>added<seq2seq4repair_space>" + ( sstable . getFilename ( ) ) ) ) ; } catch ( IOException e ) { throw new RuntimeException ( ( "Not<seq2seq4repair_space>able<seq2seq4repair_space>to<seq2seq4repair_space>add<seq2seq4repair_space>streamed<seq2seq4repair_space>file<seq2seq4repair_space>" + ( pendingFile . getFilename ( ) ) ) , e ) ; } } if ( FileStatusHandler . logger . isDebugEnabled ( ) ) FileStatusHandler . logger . debug ( ( ( ( "Sending<seq2seq4repair_space>a<seq2seq4repair_space>streaming<seq2seq4repair_space>finished<seq2seq4repair_space>message<seq2seq4repair_space>for<seq2seq4repair_space>" + pendingFile ) + "<seq2seq4repair_space>to<seq2seq4repair_space>" ) + host ) ) ; instance . sendOneWay ( streamStatus . makeStreamStatusMessage ( ) , host ) ; if ( ( StreamInManager . isDone ( host ) ) && ( StorageService . instance . isBootstrapMode ( ) ) ) { StorageService . instance . removeBootstrapSource ( host , pendingFile . getDescriptor ( ) . ksname ) ; } } }

Fix:
SSTableReader sstable = SSTableWriter . renameAndOpen ( pendingFile . getDescriptor ( ) ) ;
Buggy code:
public class Main { public static void main ( String [ ] args ) { JFrame frame = new JFrame ( "Space<seq2seq4repair_space>War" ) ; frame . setDefaultCloseOperation ( JFrame . EXIT_ON_CLOSE ) ; frame . setSize ( 400 , 650 ) ; frame . getContentPane ( ) . setLayout ( new BorderLayout ( ) ) ; <START_BUG> SpaceShip v = new SpaceShip ( 180 , 550 , 20 , 20 ) ; <END_BUG> GamePanel gp = new GamePanel ( ) ; GameEngine engine = new GameEngine ( gp , v ) ; frame . addKeyListener ( engine ) ; frame . getContentPane ( ) . add ( gp , BorderLayout . CENTER ) ; frame . setVisible ( true ) ; engine . start ( ) ; } }

Fix:
PlayerSpaceShip v = new PlayerSpaceShip ( 180 , 550 , 20 , 20 ) ;
Buggy code:
@ Repository ( "getConceptsDao" ) public class GetConceptsDaoImpl extends BaseJDBCDaoImpl implements GetConceptsDao { @ Override public List < String > getConceptsList ( ) { } @ Override public List < String > getTechnologyList ( ) { List < String > returnList = null ; StringBuilder query = new StringBuilder ( "" ) ; query . append ( "SELECT<seq2seq4repair_space>technology<seq2seq4repair_space>FROM<seq2seq4repair_space>company_technology,technology<seq2seq4repair_space>WHERE<seq2seq4repair_space>company_technology.id<seq2seq4repair_space>=<seq2seq4repair_space>technology.id" ) ; RowMapper < String > mapper = new RowMapper < String > ( ) { @ Override public String mapRow ( ResultSet resultSet , int i ) throws SQLException { <START_BUG> String technology = String . valueOf ( resultSet . getLong ( "technology_id" ) ) ; <END_BUG> return technology ; } } ; returnList = getNamedParameterJdbcTemplate ( ) . query ( query . toString ( ) , mapper ) ; return returnList ; } @ Override public List < CompanyTechnology > getCompanyTechnologiesWithScore ( ) { } }

Fix:
String technology = String . valueOf ( resultSet . getString ( "technology" ) ) ;