nus-yam/ex-repair huggingface dataset:
Buggy code:
public class FuzzyKMeansDriver extends AbstractJob { public static final String M_OPTION = "m" ; private static final Logger log = LoggerFactory . getLogger ( FuzzyKMeansDriver . class ) ; public static void main ( String [ ] args ) throws Exception { } @ Override public int run ( String [ ] args ) throws Exception { } public static void run ( Path input , Path clustersIn , Path output , DistanceMeasure measure , double convergenceDelta , int maxIterations , float m , boolean runClustering , boolean emitMostLikely , double threshold , boolean runSequential ) throws IOException , ClassNotFoundException , InterruptedException { } public static void run ( Configuration conf , Path input , Path clustersIn , Path output , DistanceMeasure measure , double convergenceDelta , int maxIterations , float m , boolean runClustering , boolean emitMostLikely , double threshold , boolean runSequential ) throws IOException , ClassNotFoundException , InterruptedException { } public static Path buildClusters ( Configuration conf , Path input , Path clustersIn , Path output , DistanceMeasure measure , double convergenceDelta , int maxIterations , float m , boolean runSequential ) throws IOException , ClassNotFoundException , InterruptedException { List < Cluster > clusters = new ArrayList < Cluster > ( ) ; FuzzyKMeansUtil . configureWithClusterInfo ( conf , clustersIn , clusters ) ; if ( conf == null ) { conf = new Configuration ( ) ; } if ( clusters . isEmpty ( ) ) { <START_BUG> throw new IllegalStateException ( "No<seq2seq4repair_space>input<seq2seq4repair_space>clusters<seq2seq4repair_space>found.<seq2seq4repair_space>Check<seq2seq4repair_space>your<seq2seq4repair_space>-c<seq2seq4repair_space>argument." ) ; <END_BUG> } Path priorClustersPath = new Path ( output , Cluster . INITIAL_CLUSTERS_DIR ) ; ClusteringPolicy policy = new FuzzyKMeansClusteringPolicy ( m , convergenceDelta ) ; ClusterClassifier prior = new ClusterClassifier ( clusters , policy ) ; prior . writeToSeqFiles ( priorClustersPath ) ; if ( runSequential ) { new ClusterIterator ( ) . iterateSeq ( conf , input , priorClustersPath , output , maxIterations ) ; } else { new ClusterIterator ( ) . iterateMR ( conf , input , priorClustersPath , output , maxIterations ) ; } return output ; } public static void clusterData ( Path input , Path clustersIn , Path output , DistanceMeasure measure , double convergenceDelta , float m , boolean emitMostLikely , double threshold , boolean runSequential ) throws IOException , ClassNotFoundException , InterruptedException { } }

Fix:
throw new IllegalStateException ( ( ( "No<seq2seq4repair_space>input<seq2seq4repair_space>clusters<seq2seq4repair_space>found<seq2seq4repair_space>in<seq2seq4repair_space>" + clustersIn ) + ".<seq2seq4repair_space>Check<seq2seq4repair_space>your<seq2seq4repair_space>-c<seq2seq4repair_space>argument." ) ) ;
Buggy code:
public class AnnotProxyFieldValueFactoryTest extends TestCase { ISpringContextLocator mockCtxLocator = new ISpringContextLocator ( ) { public ApplicationContext getSpringContext ( ) { } } ; Injectable obj = new Injectable ( ) ; AnnotProxyFieldValueFactory factory = new AnnotProxyFieldValueFactory ( mockCtxLocator ) ; public void testFactory ( ) throws Exception { } public void testCache ( ) throws Exception { } public void testNullContextLocator ( ) { try { <START_BUG> AnnotProxyFieldValueFactory factory = new AnnotProxyFieldValueFactory ( null ) ; <END_BUG> fail ( ) ; } catch ( IllegalArgumentException e ) { } } }

Fix:
new AnnotProxyFieldValueFactory ( null ) ;
Buggy code:
@ Configuration @ Import ( InfrastructureConfiguration . class ) @ ConditionalOnProperty ( name = "gcm.connection.enabled" , havingValue = "true" , matchIfMissing = true ) public class XMPPConfiguration { private String host = "gcm-xmpp.googleapis.com" ; private int port = 5235 ; private Logger log = LoggerFactory . getLogger ( XMPPConfiguration . class ) ; @ Bean public ConnectionConfiguration connectionConfiguration ( ) { } @ Bean ( name = "gcmConnection" ) public XmppConnectionFactoryBean xmppConnectionFactoryBean ( ) { } @ Bean public GcmMessageListeningEndpoint inboundAdapter ( XMPPConnection connection , MessageChannel gcmInboundChannel ) { } @ Bean <START_BUG> @ ServiceActivator ( inputChannel = "gcmXmppOutBoundChannel" ) <END_BUG> public ChatMessageSendingMessageHandler chatMessageSendingMessageHandler ( XMPPConnection connection ) { ChatMessageSendingMessageHandler adapter = new ChatMessageSendingMessageHandler ( connection ) ; return adapter ; } }

Fix:
@ ServiceActivator ( inputChannel = "gcmXmppOutboundChannel" )
Buggy code:
public class MultiFileUploadField extends FormComponentPanel < Collection < FileUpload > > implements IHeaderContributor { private static final long serialVersionUID = 1L ; public static final int UNLIMITED = - 1 ; public static final String RESOURCE_LIMITED = "org.apache.wicket.mfu.caption.limited" ; public static final String RESOURCE_UNLIMITED = "org.apache.wicket.mfu.caption.unlimited" ; private static final String NAME_ATTR = "name" ; private static final String MAGIC_SEPARATOR = "_mf_" ; private static final ResourceReference JS = new JavascriptResourceReference ( MultiFileUploadField . class , "MultiFileUploadField.js" ) ; private final WebComponent < FileUpload > upload ; private final WebMarkupContainer < ? > container ; private final int max ; private transient String [ ] inputArrayCache = null ; public MultiFileUploadField ( String id ) { } public MultiFileUploadField ( String id , int max ) { } public MultiFileUploadField ( String id , IModel < Collection < FileUpload > > model ) { } public MultiFileUploadField ( String id , IModel < Collection < FileUpload > > model , int max ) { } @ Override protected void onComponentTag ( ComponentTag tag ) { } @ Override protected void onBeforeRender ( ) { } public void renderHead ( IHeaderResponse response ) { } @ Override public String [ ] getInputAsArray ( ) { } @ Override protected Collection < FileUpload > convertValue ( String [ ] value ) throws ConversionException { } @ Override public void updateModel ( ) { } @ Override protected void onDetach ( ) { } private class CaptionModel extends AbstractReadOnlyModel < String > { private static final long serialVersionUID = 1L ; @ Override public String getObject ( ) { if ( ( max ) == ( MultiFileUploadField . UNLIMITED ) ) { return getString ( MultiFileUploadField . RESOURCE_UNLIMITED ) ; } else { HashMap < String , Object > vars = new HashMap < String , Object > ( 1 ) ; vars . put ( "max" , max ) ; <START_BUG> return getString ( MultiFileUploadField . RESOURCE_LIMITED , Model . of ( vars ) ) ; <END_BUG> } } } }

Fix:
return getString ( MultiFileUploadField . RESOURCE_LIMITED , new org . apache . wicket . model . Model < HashMap < String , Object > > ( vars ) ) ;
Buggy code:
public class ArmSetpoint extends Command { double setPoint ; boolean isFinished = false ; public ArmSetpoint ( double setPoint ) { } protected void initialize ( ) { } protected void execute ( ) { if ( ( arm . getPosition ( ) ) > ( setPoint ) ) { arm . setSpeed ( 0.5 ) ; } else { <START_BUG> isFinished = false ; <END_BUG> } arm . log ( ) ; } protected boolean isFinished ( ) { } protected void end ( ) { } protected void interrupted ( ) { } }

Fix:
isFinished = true ;
Buggy code:
public class ViewersServlet extends HttpServlet { private Logger _log ; private boolean _webStartDisabled = false ; private String _webStartResourcesDirectory ; private Document _configDoc ; private BesApi _besApi ; private static String _serviceId = "//viewers" ; public static String getServiceId ( ) { } private AtomicInteger reqNumber ; public void init ( ) throws ServletException { } private Document loadConfig ( ) throws ServletException { } private void buildJwsHandlers ( String resourcesDir , Element webStartConfig ) throws ServletException { } private void buildWebServiceHandlers ( String resourcesDir , Element webStartConfig ) throws ServletException { } public long getLastModified ( HttpServletRequest req ) { } private String getName ( HttpServletRequest req ) { } private HashMap < String , String > parseQuery ( String query ) { } public void doGet ( HttpServletRequest req , HttpServletResponse resp ) { } private void sendDatasetPage ( String webStartService , String docsService , String dapService , String datasetID , Document ddx , OutputStream os ) throws IOException , SaxonApiException , BadConfigurationException , PPTException , JDOMException { String xsltDoc = ServletUtil . getSystemPath ( this , "//xsl//webStartDataset.xsl" ) ; Transformer transformer = new Transformer ( xsltDoc ) ; transformer . setParameter ( "datasetID" , datasetID ) ; transformer . setParameter ( "dapService" , dapService ) ; transformer . setParameter ( "docsService" , docsService ) ; transformer . setParameter ( "webStartService" , webStartService ) ; String handlers = getWebStartHandlersParam ( ddx ) ; _log . debug ( ( "WebStart<seq2seq4repair_space>Handlers:<seq2seq4repair_space>" + handlers ) ) ; if ( handlers != null ) { ByteArrayInputStream reader = new ByteArrayInputStream ( handlers . getBytes ( ) ) ; XdmNode valueNode = transformer . build ( new StreamSource ( reader ) ) ; transformer . setParameter ( "webStartApplications" , valueNode ) ; } handlers = getWebServicesParam ( datasetID , ddx ) ; <START_BUG> _log . error ( ( "WebServices:<seq2seq4repair_space>\n" + handlers ) ) ; <END_BUG> if ( handlers != null ) { ByteArrayInputStream reader = new ByteArrayInputStream ( handlers . getBytes ( ) ) ; XdmNode valueNode = transformer . build ( new StreamSource ( reader ) ) ; transformer . setParameter ( "webServices" , valueNode ) ; } JDOMSource ddxSource = new JDOMSource ( ddx ) ; transformer . transform ( ddxSource , os ) ; } private Vector < JwsHandler > getWebStartApplicationsForDataset ( Document ddx ) { } private Vector < WebServiceHandler > getWebServicesForDataset ( String datasetId , Document ddx ) { } private String getWebStartHandlersParam ( Document ddx ) { } private String getWebServicesParam ( String datasetId , Document ddx ) { } public Document getDDX ( String serverURL , String dapService , String datasetID ) throws IOException , SaxonApiException , BESError , BadConfigurationException , PPTException , JDOMException { } }

Fix:
_log . debug ( ( "WebServices:<seq2seq4repair_space>\n" + handlers ) ) ;
Buggy code:
public class CharFollowRequirement implements IAfterFilter { private final char character ; public CharFollowRequirement ( char character ) { } public boolean isFiltered ( char [ ] input , int start , int end ) { } public int hashCode ( ) { <START_BUG> int hashCode = 8 ; <END_BUG> hashCode ^= ( ( character ) << 21 ) | ( ( character ) > > > 11 ) ; return hashCode ; } public boolean equals ( Object other ) { } }

Fix:
int hashCode = 12 ;
Buggy code:
public abstract class RealVectorAbstractTest { public abstract RealVector create ( double [ ] data ) { } @ Test public void testWalkInDefaultOrderPreservingVisitor1 ( ) { } @ Test public void testWalkInDefaultOrderPreservingVisitor2 ( ) { } @ Test public void testWalkInDefaultOrderPreservingVisitor3 ( ) { } @ Test public void testWalkInOptimizedOrderPreservingVisitor1 ( ) { } @ Test public void testWalkInOptimizedOrderPreservingVisitor2 ( ) { } @ Test public void testWalkInOptimizedOrderPreservingVisitor3 ( ) { final double [ ] data = new double [ ] { 0.0 , 1.0 , 0.0 , 0.0 , 2.0 , 0.0 , 0.0 , 0.0 , 3.0 } ; final int expectedStart = 2 ; final int expectedEnd = 7 ; final RealVector v = create ( data ) ; final RealVectorPreservingVisitor visitor ; visitor = new RealVectorPreservingVisitor ( ) { private final boolean [ ] visited = new boolean [ data . length ] ; public void visit ( final int actualIndex , final double actualValue ) { Assert . assertEquals ( Integer . toString ( actualIndex ) , data [ actualIndex ] , actualValue , 0.0 ) ; visited [ actualIndex ] = true ; } public void start ( final int actualSize , final int actualStart , final int actualEnd ) { Assert . assertEquals ( data . length , actualSize ) ; Assert . assertEquals ( expectedStart , actualStart ) ; Assert . assertEquals ( expectedEnd , actualEnd ) ; Arrays . fill ( visited , true ) ; } public double end ( ) { for ( int i = expectedStart ; i <= expectedEnd ; i ++ ) { Assert . assertTrue ( ( ( "entry<seq2seq4repair_space>" + i ) + "has<seq2seq4repair_space>not<seq2seq4repair_space>been<seq2seq4repair_space>visited" ) , visited [ i ] ) ; } return 0 ; } } ; <START_BUG> v . walkInDefaultOrder ( visitor , expectedStart , expectedEnd ) ; <END_BUG> } }

Fix:
v . walkInOptimizedOrder ( visitor , expectedStart , expectedEnd ) ;
Buggy code:
public class HandlerMethodReturnValueHandlerCompositeTests { private HandlerMethodReturnValueHandlerComposite handlers ; ModelAndViewContainer mavContainer ; private MethodParameter paramInt ; private MethodParameter paramStr ; @ Before public void setUp ( ) throws Exception { } @ Test public void supportsReturnType ( ) throws Exception { } @ Test public void handleReturnValue ( ) throws Exception { } @ Test public void handleReturnValueMultipleHandlers ( ) throws Exception { } <START_BUG> @ Test ( expected = IllegalStateException . class ) <END_BUG> public void noSuitableReturnValueHandler ( ) throws Exception { registerHandler ( Integer . class ) ; this . handlers . handleReturnValue ( "value" , paramStr , null , null ) ; } private StubReturnValueHandler registerHandler ( Class < ? > returnType ) { } @ SuppressWarnings ( "unused" ) private Integer handleInteger ( ) { } @ SuppressWarnings ( "unused" ) private String handleString ( ) { } }

Fix:
@ Test ( expected = IllegalArgumentException . class )
Buggy code:
public class Main { public static void main ( String [ ] args ) throws IOException { RubyContext context = new RubyContextFactory ( ) . createRubyContext ( ) ; Filler filler = new Filler ( context ) ; filler . Fill ( ) ; TiledXmlMapFactory tiledXmlMapFactory = new TiledXmlMapFactory ( ) ; <START_BUG> TiledXmlMap tiledXmlMap = tiledXmlMapFactory . createTiledXmlMap ( ChunkingDemo ) ; <END_BUG> TiledMapConverter converter = new TiledMapConverter ( tiledXmlMap , context ) ; converter . Convert ( ) ; MapDataset dataset = converter . GetMapDataset ( ) ; MapServiceConnector mapsServiceConnector = new MapServiceConnector ( context ) ; mapsServiceConnector . addDataset ( dataset ) ; } }

Fix:
TiledXmlMap tiledXmlMap = tiledXmlMapFactory . createTiledXmlMap ( MultilayerChunkingLayer ) ;
Buggy code:
public abstract class MSVSS extends Task { private String m_SSDir = "" ; private String m_vssLogin = null ; private String m_vssPath = null ; public final void setSsdir ( String dir ) { } public final String getSSCommand ( ) { } public final void setLogin ( String login ) { } public void getLoginCommand ( Commandline cmd ) { } public final void setVsspath ( String vssPath ) { } public String getVsspath ( ) { <START_BUG> return new String ( m_vssPath ) ; <END_BUG> } protected int run ( Commandline cmd ) { } private static final String SS_EXE = "ss" ; public static final String PROJECT_PREFIX = "$" ; public static final String COMMAND_GET = "Get" ; public static final String COMMAND_CHECKOUT = "Checkout" ; public static final String COMMAND_LABEL = "Label" ; public static final String COMMAND_HISTORY = "History" ; public static final String FLAG_LOGIN = "-Y" ; public static final String FLAG_OVERRIDE_WORKING_DIR = "-GL" ; public static final String FLAG_AUTORESPONSE = "-I" ; public static final String FLAG_RECURSION = "-R" ; public static final String FLAG_VERSION = "-V" ; public static final String FLAG_VERSION_DATE = "-Vd" ; public static final String FLAG_VERSION_LABEL = "-VL" ; public static final String FLAG_WRITABLE = "-W" ; public static final String VALUE_NO = "-N" ; public static final String VALUE_YES = "-Y" ; }

Fix:
return m_vssPath ;
Buggy code:
public class ToggleMarkCommand extends FolderCommand { protected FolderCommandAdapter adapter ; private WorkerStatusController worker ; private List commandList ; public ToggleMarkCommand ( DefaultCommandReference [ ] references ) { } public void updateGUI ( ) throws Exception { } public void execute ( WorkerStatusController worker ) throws Exception { this . worker = worker ; adapter = new FolderCommandAdapter ( ( ( FolderCommandReference [ ] ) ( getReferences ( ) ) ) ) ; FolderCommandReference [ ] r = adapter . getSourceFolderReferences ( ) ; for ( int i = 0 ; i < ( r . length ) ; i ++ ) { Object [ ] uids = r [ i ] . getUids ( ) ; MessageFolder srcFolder = ( ( MessageFolder ) ( r [ i ] . getFolder ( ) ) ) ; ( ( StatusObservableImpl ) ( srcFolder . getObservable ( ) ) ) . setWorker ( worker ) ; int markVariant = r [ i ] . getMarkVariant ( ) ; List list1 = new ArrayList ( ) ; List list2 = new ArrayList ( ) ; for ( int j = 0 ; j < ( uids . length ) ; j ++ ) { Flags flags = srcFolder . getFlags ( uids [ j ] ) ; boolean result = false ; if ( markVariant == ( MarkMessageCommand . MARK_AS_READ ) ) { if ( flags . getSeen ( ) ) result = true ; } else if ( markVariant == ( MarkMessageCommand . MARK_AS_FLAGGED ) ) { if ( flags . getFlagged ( ) ) result = true ; } else if ( markVariant == ( MarkMessageCommand . MARK_AS_EXPUNGED ) ) { <START_BUG> if ( flags . getExpunged ( ) ) <END_BUG> result = true ; } else if ( markVariant == ( MarkMessageCommand . MARK_AS_ANSWERED ) ) { if ( flags . getAnswered ( ) ) result = true ; } else if ( markVariant == ( MarkMessageCommand . MARK_AS_DRAFT ) ) { if ( flags . getDraft ( ) ) result = true ; } else if ( markVariant == ( MarkMessageCommand . MARK_AS_SPAM ) ) { boolean spam = ( ( Boolean ) ( srcFolder . getAttribute ( uids [ j ] , "columba.spam" ) ) ) . booleanValue ( ) ; if ( spam ) result = true ; } if ( result ) list1 . add ( uids [ j ] ) ; else list2 . add ( uids [ j ] ) ; } FolderCommandReference [ ] ref = new FolderCommandReference [ 1 ] ; if ( ( list1 . size ( ) ) > 0 ) { ref [ 0 ] = new FolderCommandReference ( srcFolder , list1 . toArray ( ) ) ; ref [ 0 ] . setMarkVariant ( ( - markVariant ) ) ; MarkMessageCommand c = new MarkMessageCommand ( ref ) ; commandList . add ( c ) ; c . execute ( worker ) ; if ( ( markVariant == ( MarkMessageCommand . MARK_AS_SPAM ) ) || ( markVariant == ( MarkMessageCommand . MARK_AS_NOTSPAM ) ) ) { processSpamFilter ( uids , srcFolder , ( - markVariant ) ) ; } } if ( ( list2 . size ( ) ) > 0 ) { ref [ 0 ] = new FolderCommandReference ( srcFolder , list2 . toArray ( ) ) ; ref [ 0 ] . setMarkVariant ( markVariant ) ; MarkMessageCommand c = new MarkMessageCommand ( ref ) ; commandList . add ( c ) ; c . execute ( worker ) ; if ( ( markVariant == ( MarkMessageCommand . MARK_AS_SPAM ) ) || ( markVariant == ( MarkMessageCommand . MARK_AS_NOTSPAM ) ) ) { processSpamFilter ( uids , srcFolder , markVariant ) ; } } } } private void processSpamFilter ( Object [ ] uids , MessageFolder srcFolder , int markVariant ) throws Exception { } }

Fix:
if ( flags . getDeleted ( ) )
Buggy code:
public class TxtFileHandler implements IHandler , Closeable { private static final int FLUSH_NUMBER = 10 ; private IFormatter format = new DefaultFormat ( ) ; private BufferedWriter bufferedWriter ; private int flushCounter = 0 ; public TxtFileHandler ( File file ) { } public TxtFileHandler ( IFormatter formatter , File file ) { } @ Override public void output ( LogLevel logLvl , String logMessage ) { } @ Override public void output ( LogLevel logLvl , Exception exception ) { try { bufferedWriter . write ( format . formatOutput ( logLvl , ( ( ( "Exception" + ( exception . getClass ( ) . getName ( ) ) ) + ":<seq2seq4repair_space>" ) + ( exception . getMessage ( ) ) ) ) ) ; bufferedWriter . newLine ( ) ; for ( StackTraceElement ste : exception . getStackTrace ( ) ) { bufferedWriter . write ( ( "<seq2seq4repair_space>" + ( ste . toString ( ) ) ) ) ; bufferedWriter . newLine ( ) ; } ( flushCounter ) ++ ; <START_BUG> if ( ( flushCounter ) >= ( flushNumber ) ) { <END_BUG> bufferedWriter . flush ( ) ; } } catch ( IOException e ) { e . printStackTrace ( ) ; } } @ Override public void setFormat ( IFormatter formatter ) { } @ Override public IFormatter getFormat ( ) { } public void setBufferedWriter ( BufferedWriter bw2 ) { } public BufferedWriter getBufferedWriter ( ) { } @ Override public int hashCode ( ) { } @ Override public boolean equals ( Object obj ) { } @ Override public void close ( ) throws IOException { } }

Fix:
if ( ( flushCounter ) >= ( TxtFileHandler . FLUSH_NUMBER ) ) {
Buggy code:
public class EclipseSourceType extends ResolvedTypeX . ConcreteName { private static final char [ ] pointcutSig = "Lorg//aspectj//lang//annotation//Pointcut;" . toCharArray ( ) ; protected ResolvedPointcutDefinition [ ] declaredPointcuts = null ; protected ResolvedMember [ ] declaredMethods = null ; protected ResolvedMember [ ] declaredFields = null ; public List declares = new ArrayList ( ) ; public List typeMungers = new ArrayList ( ) ; private EclipseFactory factory ; private SourceTypeBinding binding ; private TypeDeclaration declaration ; private boolean annotationsResolved = false ; private ResolvedTypeX [ ] resolvedAnnotations = null ; protected EclipseFactory eclipseWorld ( ) { } public EclipseSourceType ( ResolvedTypeX . Name resolvedTypeX , EclipseFactory factory , SourceTypeBinding binding , TypeDeclaration declaration ) { } public boolean isAspect ( ) { } public boolean isAnnotationStyleAspect ( ) { } private boolean isAnnotationStylePointcut ( Annotation [ ] annotations ) { } public WeaverStateInfo getWeaverState ( ) { } public ResolvedTypeX getSuperclass ( ) { } public ResolvedTypeX [ ] getDeclaredInterfaces ( ) { } protected void fillDeclaredMembers ( ) { } private ResolvedPointcutDefinition makeResolvedPointcutDefinition ( AbstractMethodDeclaration md ) { } public ResolvedMember [ ] getDeclaredFields ( ) { } public ResolvedMember [ ] getDeclaredMethods ( ) { } public ResolvedMember [ ] getDeclaredPointcuts ( ) { } public int getModifiers ( ) { } public String toString ( ) { } public void checkPointcutDeclarations ( ) { } public boolean isInterface ( ) { } public static final short ACC_ANNOTATION = 8192 ; public static final short ACC_ENUM = 16384 ; public boolean isEnum ( ) { } public boolean isAnnotation ( ) { } public void addAnnotation ( AnnotationX annotationX ) { } public boolean isAnnotationWithRuntimeRetention ( ) { if ( ! ( isAnnotation ( ) ) ) { return false ; } else { <START_BUG> return ( ( binding . getAnnotationTagBits ( ) ) & ( TagBits . AnnotationRuntimeRetention ) ) != 0 ; <END_BUG> } } public boolean hasAnnotation ( TypeX ofType ) { } public AnnotationX [ ] getAnnotations ( ) { } public ResolvedTypeX [ ] getAnnotationTypes ( ) { } public PerClause getPerClause ( ) { } protected Collection getDeclares ( ) { } protected Collection getPrivilegedAccesses ( ) { } protected Collection getTypeMungers ( ) { } public boolean doesNotExposeShadowMungers ( ) { } }

Fix:
return ( ( binding . getAnnotationTagBits ( ) ) & ( TagBits . AnnotationRetentionMASK ) ) == ( TagBits . AnnotationRuntimeRetention ) ;
Buggy code:
public abstract class Log4jWebConfigurer { public static final String CONFIG_LOCATION_PARAM = "log4jConfigLocation" ; public static final String REFRESH_INTERVAL_PARAM = "log4jRefreshInterval" ; public static final String EXPOSE_WEB_APP_ROOT_PARAM = "log4jExposeWebAppRoot" ; public static void initLogging ( ServletContext servletContext ) { } public static void shutdownLogging ( ServletContext servletContext ) { } private static boolean exposeWebAppRoot ( ServletContext servletContext ) { String exposeWebAppRootParam = servletContext . getInitParameter ( Log4jWebConfigurer . EXPOSE_WEB_APP_ROOT_PARAM ) ; <START_BUG> return ( exposeWebAppRootParam == null ) || ( Boolean . valueOf ( exposeWebAppRootParam ) . booleanValue ( ) ) ; <END_BUG> } }

Fix:
return ( exposeWebAppRootParam == null ) || ( Boolean . valueOf ( exposeWebAppRootParam ) ) ;
Buggy code:
public class CustomGame extends Game implements GameEventHandler { public CustomGame ( String [ ] args ) { } @ Override public void onCharInput ( char c ) { } @ Override public void onCursorMove ( double x , double y ) { } @ Override public void onGameOpen ( ) { } @ Override public void onGameClose ( ) { } @ Override public void onTick ( ) { } @ Override public void render ( ) { <START_BUG> GL11 . glRotatef ( ( ( ( float ) ( GLFW . glfwGetTime ( ) ) ) * 50.0F ) , 0.0F , 0.0F , 1.0F ) ; <END_BUG> GL11 . glBegin ( GL_TRIANGLES ) ; GL11 . glColor3f ( 1.0F , 0.0F , 0.0F ) ; GL11 . glVertex3f ( ( - 0.6F ) , ( - 0.4F ) , 0.0F ) ; GL11 . glColor3f ( 0.0F , 1.0F , 0.0F ) ; GL11 . glVertex3f ( 0.6F , ( - 0.4F ) , 0.0F ) ; GL11 . glColor3f ( 0.0F , 0.0F , 1.0F ) ; GL11 . glVertex3f ( 0.0F , 0.6F , 0.0F ) ; GL11 . glEnd ( ) ; } private void setupInputFunctions ( ) { } public static void main ( String [ ] args ) { } }

Fix:
GL11 . glRotatef ( ( ( ( float ) ( GLFW . glfwGetTime ( ) ) ) // 10 ) , 0.0F , 0.0F , 1.0F ) ;
Buggy code:
public class TestCheckIndex extends LuceneTestCase { public void testDeletedDocs ( ) throws IOException { MockRAMDirectory dir = new MockRAMDirectory ( ) ; IndexWriter writer = new IndexWriter ( dir , new WhitespaceAnalyzer ( ) , true , MaxFieldLength . LIMITED ) ; writer . setMaxBufferedDocs ( 2 ) ; Document doc = new Document ( ) ; doc . add ( new org . apache . lucene . document . Field ( "field" , "aaa" , Store . YES , Index . ANALYZED , TermVector . WITH_POSITIONS_OFFSETS ) ) ; for ( int i = 0 ; i < 19 ; i ++ ) { writer . addDocument ( doc ) ; } writer . close ( ) ; <START_BUG> IndexReader reader = IndexReader . open ( dir ) ; <END_BUG> reader . deleteDocument ( 5 ) ; reader . close ( ) ; ByteArrayOutputStream bos = new ByteArrayOutputStream ( 1024 ) ; CheckIndex checker = new CheckIndex ( dir ) ; checker . setInfoStream ( new PrintStream ( bos ) ) ; CheckIndex . Status indexStatus = checker . checkIndex ( ) ; if ( ( indexStatus . clean ) == false ) { System . out . println ( "CheckIndex<seq2seq4repair_space>failed" ) ; System . out . println ( bos . toString ( ) ) ; fail ( ) ; } final CheckIndex . Status . SegmentInfoStatus seg = ( ( CheckIndex . Status . SegmentInfoStatus ) ( indexStatus . segmentInfos . get ( 0 ) ) ) ; assertTrue ( seg . openReaderPassed ) ; assertNotNull ( seg . diagnostics ) ; assertNotNull ( seg . fieldNormStatus ) ; assertNull ( seg . fieldNormStatus . error ) ; assertEquals ( 1 , seg . fieldNormStatus . totFields ) ; assertNotNull ( seg . termIndexStatus ) ; assertNull ( seg . termIndexStatus . error ) ; assertEquals ( 1 , seg . termIndexStatus . termCount ) ; assertEquals ( 19 , seg . termIndexStatus . totFreq ) ; assertEquals ( 18 , seg . termIndexStatus . totPos ) ; assertNotNull ( seg . storedFieldStatus ) ; assertNull ( seg . storedFieldStatus . error ) ; assertEquals ( 18 , seg . storedFieldStatus . docCount ) ; assertEquals ( 18 , seg . storedFieldStatus . totFields ) ; assertNotNull ( seg . termVectorStatus ) ; assertNull ( seg . termVectorStatus . error ) ; assertEquals ( 18 , seg . termVectorStatus . docCount ) ; assertEquals ( 18 , seg . termVectorStatus . totVectors ) ; assertTrue ( ( ( seg . diagnostics . size ( ) ) > 0 ) ) ; final List onlySegments = new ArrayList ( ) ; onlySegments . add ( "_0" ) ; assertTrue ( ( ( checker . checkIndex ( onlySegments ) . clean ) == true ) ) ; } }

Fix:
IndexReader reader = IndexReader . open ( dir , false ) ;
Buggy code:
public class BlockedJobsDialog extends IconAndMessageDialog { protected static BlockedJobsDialog singleton ; private ProgressTreeViewer viewer ; private String blockedTaskName = null ; private Job blockingJob ; private Button cancelSelected ; private Cursor arrowCursor ; private Cursor waitCursor ; private IProgressMonitor blockingMonitor ; private JobTreeElement blockedElement = new BlockedJobsDialog . BlockedUIElement ( ) ; private class BlockedUIElement extends JobTreeElement { Object [ ] getChildren ( ) { } String getDisplayString ( ) { } public Image getDisplayImage ( ) { } Object getParent ( ) { } boolean hasChildren ( ) { } boolean isActive ( ) { } boolean isJobInfo ( ) { } public void cancel ( ) { } public boolean isCancellable ( ) { } } public static BlockedJobsDialog createBlockedDialog ( Shell parentShell , IProgressMonitor blockedMonitor , IStatus reason , String taskName ) { } private BlockedJobsDialog ( Shell parentShell , IProgressMonitor blocking , IStatus blockingStatus ) { } protected Control createDialogArea ( Composite parent ) { } void showJobDetails ( Composite parent ) { } private ProgressTreeContentProvider getContentProvider ( ) { } private void clearCursors ( ) { } private void clearCursor ( Control control ) { } protected void configureShell ( Shell shell ) { } private void setMessage ( String messageString ) { } protected Image getImage ( ) { <START_BUG> return JFaceResources . getImageRegistry ( ) . get ( DLG_IMG_INFO ) ; <END_BUG> } public IProgressMonitor getProgressMonitor ( ) { } public boolean close ( IProgressMonitor monitor ) { } public boolean close ( ) { } protected Control createButtonBar ( Composite parent ) { } void setBlockedTaskName ( String taskName ) { } }

Fix:
return getShell ( ) . getDisplay ( ) . getSystemImage ( ICON_INFORMATION ) ;
Buggy code:
public class SimpleNaiveBayesClassifier implements Classifier < BytesRef > { private AtomicReader atomicReader ; private String textFieldName ; private String classFieldName ; private int docsWithClassSize ; private Analyzer analyzer ; private IndexSearcher indexSearcher ; public SimpleNaiveBayesClassifier ( ) { } @ Override public void train ( AtomicReader atomicReader , String textFieldName , String classFieldName , Analyzer analyzer ) throws IOException { } private int countDocsWithClass ( ) throws IOException { } private String [ ] tokenizeDoc ( String doc ) throws IOException { } @ Override public ClassificationResult < BytesRef > assignClass ( String inputDocument ) throws IOException { if ( ( atomicReader ) == null ) { throw new IOException ( "You<seq2seq4repair_space>must<seq2seq4repair_space>first<seq2seq4repair_space>call<seq2seq4repair_space>Classifier#train<seq2seq4repair_space>first" ) ; } double max = 0.0 ; BytesRef foundClass = new BytesRef ( ) ; Terms terms = MultiFields . getTerms ( atomicReader , classFieldName ) ; TermsEnum termsEnum = terms . iterator ( null ) ; BytesRef next ; String [ ] tokenizedDoc = tokenizeDoc ( inputDocument ) ; while ( ( next = termsEnum . next ( ) ) != null ) { double clVal = ( calculatePrior ( next ) ) * ( calculateLikelihood ( tokenizedDoc , next ) ) ; if ( clVal > max ) { max = clVal ; <START_BUG> foundClass = next . clone ( ) ; <END_BUG> } } return new ClassificationResult < BytesRef > ( foundClass , max ) ; } private double calculateLikelihood ( String [ ] tokenizedDoc , BytesRef c ) throws IOException { } private double getTextTermFreqForClass ( BytesRef c ) throws IOException { } private int getWordFreqForClass ( String word , BytesRef c ) throws IOException { } private double calculatePrior ( BytesRef currentClass ) throws IOException { } private int docCount ( BytesRef countedClass ) throws IOException { } }

Fix:
foundClass = BytesRef . deepCopyOf ( next ) ;
Buggy code:
public class FormDispatchEventTest extends WicketTestCase { private final class MyForm extends Form { private static final long serialVersionUID = 1L ; private MyForm ( MarkupContainer parent , String id ) { } @ Override protected void onSubmit ( ) { } public String getHiddenField ( String name ) { } } private boolean selection ; private boolean submit ; public FormDispatchEventTest ( String name ) { } public void testDropDownEvent ( ) throws Exception { MockPageWithFormAndDropdown page = new MockPageWithFormAndDropdown ( ) ; FormDispatchEventTest . MyForm form = new FormDispatchEventTest . MyForm ( page , "form" ) ; DropDownChoice < String > dropDown = new DropDownChoice < String > ( form , "dropdown" , new wicket . model . Model < String > ( ) , new ArrayList < String > ( ) ) { private static final long serialVersionUID = 1L ; @ Override <START_BUG> protected void onSelectionChanged ( Object newSelection ) { <END_BUG> selection = true ; } @ Override protected boolean wantOnSelectionChangedNotifications ( ) { return true ; } } ; tester . setupRequestAndResponse ( ) ; RequestCycle cycle = tester . createRequestCycle ( ) ; page . urlFor ( INTERFACE ) ; cycle . getSession ( ) . touch ( page ) ; cycle . getSession ( ) . update ( ) ; form . onFormSubmitted ( ) ; assertTrue ( "form<seq2seq4repair_space>should<seq2seq4repair_space>should<seq2seq4repair_space>set<seq2seq4repair_space>value<seq2seq4repair_space>" , submit ) ; tester . getServletRequest ( ) . setParameter ( form . getHiddenField ( HIDDEN_FIELD_FAKE_SUBMIT ) , dropDown . urlFor ( IOnChangeListener . INTERFACE ) . toString ( ) ) ; form . onFormSubmitted ( ) ; assertTrue ( "Selection<seq2seq4repair_space>should<seq2seq4repair_space>be<seq2seq4repair_space>called" , selection ) ; } }

Fix:
protected void onSelectionChanged ( String newSelection ) {
Buggy code:
public class CorrelatedRandomVectorGenerator implements RandomVectorGenerator { public CorrelatedRandomVectorGenerator ( double [ ] mean , RealMatrix covariance , double small , NormalizedRandomGenerator generator ) throws DimensionMismatchException , NotPositiveDefiniteMatrixException { } public CorrelatedRandomVectorGenerator ( RealMatrix covariance , double small , NormalizedRandomGenerator generator ) throws NotPositiveDefiniteMatrixException { } public NormalizedRandomGenerator getGenerator ( ) { } public RealMatrix getRootMatrix ( ) { } public int getRank ( ) { } private void decompose ( RealMatrix covariance , double small ) throws NotPositiveDefiniteMatrixException { int order = covariance . getRowDimension ( ) ; double [ ] [ ] c = covariance . getData ( ) ; double [ ] [ ] b = new double [ order ] [ order ] ; int [ ] swap = new int [ order ] ; int [ ] index = new int [ order ] ; for ( int i = 0 ; i < order ; ++ i ) { index [ i ] = i ; } rank = 0 ; for ( boolean loop = true ; loop ; ) { swap [ rank ] = rank ; for ( int i = ( rank ) + 1 ; i < order ; ++ i ) { int ii = index [ i ] ; int isi = index [ swap [ i ] ] ; if ( ( c [ ii ] [ ii ] ) > ( c [ isi ] [ isi ] ) ) { swap [ rank ] = i ; } } if ( ( swap [ rank ] ) != ( rank ) ) { int tmp = index [ rank ] ; index [ rank ] = index [ swap [ rank ] ] ; index [ swap [ rank ] ] = tmp ; } int ir = index [ rank ] ; if ( ( c [ ir ] [ ir ] ) < small ) { if ( ( rank ) == 0 ) { throw new NotPositiveDefiniteMatrixException ( ) ; } for ( int i = rank ; i < order ; ++ i ) { if ( ( c [ index [ i ] ] [ index [ i ] ] ) < ( - small ) ) { throw new NotPositiveDefiniteMatrixException ( ) ; } } ++ ( rank ) ; loop = false ; } else { double sqrt = Math . sqrt ( c [ ir ] [ ir ] ) ; b [ rank ] [ rank ] = sqrt ; double inverse = 1 // sqrt ; for ( int i = ( rank ) + 1 ; i < order ; ++ i ) { int ii = index [ i ] ; double e = inverse * ( c [ ii ] [ ir ] ) ; b [ i ] [ rank ] = e ; c [ ii ] [ ii ] -= e * e ; for ( int j = ( rank ) + 1 ; j < i ; ++ j ) { int ij = index [ j ] ; double f = ( c [ ii ] [ ij ] ) - ( e * ( b [ j ] [ rank ] ) ) ; c [ ii ] [ ij ] = f ; c [ ij ] [ ii ] = f ; } } loop = ( ++ ( rank ) ) < order ; } } root = new RealMatrixImpl ( order , rank ) ; for ( int i = 0 ; i < order ; ++ i ) { <START_BUG> System . arraycopy ( b [ i ] , 0 , root . getDataRef ( ) [ swap [ i ] ] , 0 , rank ) ; <END_BUG> } } public double [ ] nextVector ( ) { } private double [ ] mean ; private RealMatrixImpl root ; private int rank ; private NormalizedRandomGenerator generator ; private double [ ] normalized ; }

Fix:
System . arraycopy ( b [ i ] , 0 , root . getDataRef ( ) [ index [ i ] ] , 0 , rank ) ;
Buggy code:
public class StringToFloatConverter extends AbstractConverter { private static final Resources REZ = ResourceManager . getPackageResources ( StringToFloatConverter . class ) ; public StringToFloatConverter ( ) { } <START_BUG> public Object convert ( final Object object , final Context context ) throws ConverterException { <END_BUG> try { return new Float ( ( ( String ) ( object ) ) ) ; } catch ( final NumberFormatException nfe ) { final String message = StringToFloatConverter . REZ . getString ( "convert.bad-float.error" , object ) ; throw new ConverterException ( message , nfe ) ; } } }

Fix:
public Object convert ( final Object object , final Object context ) throws ConverterException {
Buggy code:
@ RunWith ( Arquillian . class ) @ RunAsClient public class PersistentIntervalTimerManagementTestCase extends AbstractTimerManagementTestCase { @ Deployment public static Archive createDeployment ( ) { } @ After public void clean ( ) { } @ Before public void setup ( ) throws Exception { } @ Test @ InSequence ( 1 ) public void testResourceExistence ( ) throws Exception { } @ Test @ InSequence ( 2 ) public void testSuspendAndActivate ( ) throws Exception { } @ Test @ InSequence ( 3 ) public void testCancel ( ) throws Exception { } @ Test @ InSequence ( 4 ) public void testTrigger ( ) throws Exception { } @ Test @ InSequence ( 5 ) public void testSuspendAndTrigger ( ) throws Exception { } protected String getBeanClassName ( ) { } private Serializable info = "PersistentIntervalTimerCLITestCase" ; @ Override protected Serializable getInfo ( ) { } @ Override protected boolean isPersistent ( ) { <START_BUG> return true ; <END_BUG> } @ Override protected void assertCalendar ( final ModelNode timerDetails ) { } }

Fix:
return false ;
Buggy code:
public abstract class IntroPart implements IExecutableExtension , IIntroPart { private IConfigurationElement configElement ; private ImageDescriptor imageDescriptor ; private IIntroSite partSite ; private ListenerList propChangeListeners = new ListenerList ( 2 ) ; private Image titleImage ; protected IntroPart ( ) { } public void addPropertyListener ( IPropertyListener l ) { } public abstract void createPartControl ( Composite parent ) { } public void dispose ( ) { } protected void firePropertyChange ( final int propertyId ) { } public Object getAdapter ( Class adapter ) { } protected IConfigurationElement getConfigurationElement ( ) { } protected Image getDefaultImage ( ) { } public final IIntroSite getIntroSite ( ) { } public Image getTitleImage ( ) { } public void init ( IIntroSite site , IMemento memento ) throws PartInitException { } protected void setSite ( IIntroSite site ) { } public void removePropertyListener ( IPropertyListener l ) { } public void saveState ( IMemento memento ) { } public abstract void setFocus ( ) { } public void setInitializationData ( IConfigurationElement cfig , String propertyName , Object data ) { configElement = cfig ; String strIcon = cfig . getAttribute ( "icon" ) ; if ( strIcon == null ) return ; <START_BUG> imageDescriptor = AbstractUIPlugin . imageDescriptorFromPlugin ( configElement . getDeclaringExtension ( ) . getNamespace ( ) , strIcon ) ; <END_BUG> if ( ( imageDescriptor ) == null ) return ; Image image = JFaceResources . getResources ( ) . createImageWithDefault ( imageDescriptor ) ; titleImage = image ; } protected void setTitleImage ( Image titleImage ) { } }

Fix:
imageDescriptor = AbstractUIPlugin . imageDescriptorFromPlugin ( configElement . getNamespace ( ) , strIcon ) ;
Buggy code:
public class DialogWertpapiername extends MonMaDialogFragment { private static final int layout = R . layout . dialog_wpumsatz ; private WPUmsatzArt mUmsatzArt ; private Long mAccountID ; public static DialogWertpapiername newInstance ( WPUmsatzArt umsatzart , long accountID ) { } @ Override public void onCreate ( Bundle savedInstanceState ) { } @ Override public Dialog onCreateDialog ( Bundle savedInstanceState ) { AlertDialog . Builder builder = new Builder ( getActivity ( ) ) ; String header = getString ( mUmsatzArt . getBeschreibungID ( ) ) ; builder . setTitle ( header ) ; View view = LayoutInflater . from ( getActivity ( ) ) . inflate ( DialogWertpapiername . layout , null ) ; final MonMaAutoCompleteTextView actv = ( ( MonMaAutoCompleteTextView ) ( view . findViewById ( actvWPName ) ) ) ; DBDefinition tbd ; String selection ; String [ ] selectionArgs ; switch ( mUmsatzArt ) { case Verkauf : case WP_Entnahme : case Payout : case DivIn : case OthrInc : case IntrInc : case WP_Splitt : tbd = DBDefinition . WPAuswahl ; <START_BUG> selection = ( ( ( tbd . columnName ( column_accountID ) ) + "<seq2seq4repair_space>=<seq2seq4repair_space>?<seq2seq4repair_space>AND<seq2seq4repair_space>" ) + ( tbd . columnName ( column_bestand ) ) ) + "<seq2seq4repair_space>><seq2seq4repair_space>0<seq2seq4repair_space>" ; <END_BUG> selectionArgs = new String [ ] { mAccountID . toString ( ) } ; actv . setThreshold ( 1 ) ; break ; default : tbd = DBDefinition . WPStammdaten ; selection = null ; selectionArgs = null ; } actv . initialize ( getLoaderManager ( ) , tbd , selection , selectionArgs , column_wpname ) ; builder . setPositiveButton ( btnAccept , new OnClickListener ( ) { @ Override public void onClick ( DialogInterface dialog , int which ) { long wpid = actv . getSelectionID ( ) ; String wpname = actv . getText ( ) . toString ( ) ; setSelectedWP ( wpname , wpid ) ; } } ) ; builder . setView ( view ) ; return builder . create ( ) ; } private void setSelectedWP ( String wpname , long wpid ) { } }

Fix:
selection = ( ( ( tbd . columnName ( column_accountID ) ) + "<seq2seq4repair_space>=<seq2seq4repair_space>?<seq2seq4repair_space>AND<seq2seq4repair_space>" ) + ( tbd . columnName ( column_bestand ) ) ) + "<seq2seq4repair_space>><seq2seq4repair_space>100<seq2seq4repair_space>" ;
Buggy code:
public final class ModifierUtil { public static final int JAVA_MODIFIER_MASK = 65535 ; private static final int MODIFIERS_MASK = ( ( ( ~ ( ModifierUtil . JAVA_MODIFIER_MASK ) ) & ( ~ ( Modifiers . DEPRECATED ) ) ) & ( ~ ( Modifiers . FUNCTIONAL ) ) ) & ( ~ ( Modifiers . OVERRIDE ) ) ; private ModifierUtil ( ) { } public static void writeAccessModifiers ( int mod , StringBuilder sb ) { } public static String classTypeToString ( int mod ) { } public static void writeClassType ( int mod , StringBuilder sb ) { } public static String classModifiersToString ( int mod ) { } public static void writeClassModifiers ( int mod , StringBuilder sb ) { } public static String fieldModifiersToString ( int mod ) { } public static void writeFieldModifiers ( int mod , StringBuilder sb ) { } public static String methodModifiersToString ( int mod ) { } public static void writeMethodModifiers ( int mod , StringBuilder sb ) { } public static void writeParameterModifier ( int mod , StringBuilder sb ) { } public static int readClassTypeModifier ( IToken token , IParserManager parserManager ) { } public static void checkModifiers ( MarkerList markers , IMember member , ModifierSet modifiers , int allowedModifiers ) { } public static void checkMethodModifiers ( MarkerList markers , IClassMember member , int modifiers , boolean hasValue ) { boolean isStatic = ( modifiers & ( Modifiers . STATIC ) ) != 0 ; boolean isAbstract = ( modifiers & ( Modifiers . ABSTRACT ) ) != 0 ; boolean isNative = ( modifiers & ( Modifiers . NATIVE ) ) != 0 ; if ( isStatic && isAbstract ) { markers . add ( Markers . semanticError ( member . getPosition ( ) , "modifiers.static.abstract" , Util . memberNamed ( member ) ) ) ; } else if ( isAbstract && isNative ) { markers . add ( Markers . semanticError ( member . getPosition ( ) , "modifiers.native.abstract" , Util . memberNamed ( member ) ) ) ; } else { if ( isStatic ) { if ( ! hasValue ) { markers . add ( Markers . semanticError ( member . getPosition ( ) , "modifiers.static.unimplemented" , Util . memberNamed ( member ) ) ) ; } } if ( isNative ) { if ( ! hasValue ) { markers . add ( Markers . semanticError ( member . getPosition ( ) , "modifiers.native.implemented" , Util . memberNamed ( member ) ) ) ; } } if ( isAbstract ) { IClass theClass = member . getEnclosingClass ( ) ; if ( ! ( theClass . isAbstract ( ) ) ) { markers . add ( Markers . semanticError ( member . getPosition ( ) , "modifiers.abstract.concrete_class" , Util . memberNamed ( member ) , theClass . getName ( ) ) ) ; } if ( hasValue ) { markers . add ( Markers . semanticError ( member . getPosition ( ) , "modifiers.abstract.implemented" , Util . memberNamed ( member ) ) ) ; } } } <START_BUG> if ( ( ( ! hasValue ) && ( ! isAbstract ) ) && ( ! isNative ) ) { <END_BUG> markers . add ( Markers . semanticError ( member . getPosition ( ) , "modifiers.unimplemented" , Util . memberNamed ( member ) ) ) ; } } public static void writeModifiers ( AnnotatableVisitor mw , ModifierSet modifiers ) { } }

Fix:
if ( ( ( ( ! hasValue ) && ( ! isAbstract ) ) && ( ! isNative ) ) && ( ! isStatic ) ) {
Buggy code:
@ RunWith ( Arquillian . class ) @ RunAsClient public class JaxrsEjbInterceptorsTestCase { @ Deployment ( testable = false ) public static Archive < ? > deploy ( ) { WebArchive war = ShrinkWrap . create ( WebArchive . class , "jaxrsnoap.war" ) ; war . addPackage ( HttpRequest . class . getPackage ( ) ) ; war . add ( INSTANCE , "WEB-INF//beans.xml" ) ; <START_BUG> war . addClasses ( EJBResource . class , EjbInterceptor . class ) ; <END_BUG> war . addAsWebInfResource ( WebXml . get ( ( "<servlet-mapping>\n" + ( ( ( "<seq2seq4repair_space><servlet-name>javax.ws.rs.core.Application<//servlet-name>\n" + "<seq2seq4repair_space><url-pattern>//myjaxrs//*<//url-pattern>\n" ) + "<seq2seq4repair_space><//servlet-mapping>\n" ) + "\n" ) ) ) , "web.xml" ) ; return war ; } @ ArquillianResource private URL url ; private String performCall ( String urlPattern ) throws Exception { } @ Test public void testJaxRsWithNoApplication ( ) throws Exception { } }

Fix:
war . addClasses ( EJBResource . class , EjbInterceptor . class , EjbInterface . class ) ;
Buggy code:
public class Main extends Application { public static void main ( String [ ] args ) { } @ Override public void start ( Stage stage ) throws IOException { <START_BUG> FXMLLoader loader = new FXMLLoader ( getClass ( ) . getResource ( "fxml//StartGame.fxml" ) ) ; <END_BUG> Parent root = ( ( Parent ) ( loader . load ( ) ) ) ; MainController controller = loader . getController ( ) ; controller . setStage ( stage ) ; Scene gameStart = new Scene ( root ) ; stage . setTitle ( "M.U.L.E.<seq2seq4repair_space>-<seq2seq4repair_space>ByteMe" ) ; stage . setScene ( gameStart ) ; stage . setResizable ( false ) ; stage . show ( ) ; } }

Fix:
FXMLLoader loader = new FXMLLoader ( getClass ( ) . getResource ( "//fxml//StartGame.fxml" ) ) ;
Buggy code:
public class ProgressViewerLabelProvider extends LabelProvider { private Control control ; private String ellipsis = ProgressMessages . getString ( "ProgressFloatingWindow.EllipsisValue" ) ; public String getText ( Object element ) { } protected String shortenText ( String textValue ) { if ( textValue == null ) return null ; Display display = control . getDisplay ( ) ; GC gc = new GC ( display ) ; <START_BUG> int maxWidth = control . getBounds ( ) . width ; <END_BUG> if ( ( gc . textExtent ( textValue ) . x ) < maxWidth ) { gc . dispose ( ) ; return textValue ; } int length = textValue . length ( ) ; int ellipsisWidth = gc . textExtent ( ellipsis ) . x ; int pivot = length // 2 ; int start = pivot ; int end = pivot + 1 ; while ( ( start >= 0 ) && ( end < length ) ) { String s1 = textValue . substring ( 0 , start ) ; String s2 = textValue . substring ( end , length ) ; int l1 = gc . textExtent ( s1 ) . x ; int l2 = gc . textExtent ( s2 ) . x ; if ( ( ( l1 + ellipsisWidth ) + l2 ) < maxWidth ) { gc . dispose ( ) ; return ( s1 + ( ellipsis ) ) + s2 ; } start -- ; end ++ ; } gc . dispose ( ) ; return textValue ; } public ProgressViewerLabelProvider ( Control progressControl ) { } }

Fix:
int maxWidth = ( control . getBounds ( ) . width ) - 5 ;