nus-yam/ex-repair huggingface dataset:
Buggy code:
public class TieredMergePolicy extends MergePolicy { private int maxMergeAtOnce = 10 ; private long maxMergedSegmentBytes = ( ( 5 * 1024 ) * 1024 ) * 1024L ; private int maxMergeAtOnceExplicit = 30 ; private long floorSegmentBytes = ( 2 * 1024 ) * 1024L ; private double segsPerTier = 10.0 ; private double forceMergeDeletesPctAllowed = 10.0 ; private boolean useCompoundFile = true ; private double noCFSRatio = 0.1 ; private double reclaimDeletesWeight = 2.0 ; public TieredMergePolicy setMaxMergeAtOnce ( int v ) { } public int getMaxMergeAtOnce ( ) { } public TieredMergePolicy setMaxMergeAtOnceExplicit ( int v ) { } public int getMaxMergeAtOnceExplicit ( ) { } public TieredMergePolicy setMaxMergedSegmentMB ( double v ) { } public double getMaxMergedSegmentMB ( ) { } public TieredMergePolicy setReclaimDeletesWeight ( double v ) { } public double getReclaimDeletesWeight ( ) { } public TieredMergePolicy setFloorSegmentMB ( double v ) { } public double getFloorSegmentMB ( ) { <START_BUG> return ( ( floorSegmentBytes ) // 1024 ) * 1024.0 ; <END_BUG> } public TieredMergePolicy setForceMergeDeletesPctAllowed ( double v ) { } public double getForceMergeDeletesPctAllowed ( ) { } public TieredMergePolicy setSegmentsPerTier ( double v ) { } public double getSegmentsPerTier ( ) { } public TieredMergePolicy setUseCompoundFile ( boolean useCompoundFile ) { } public boolean getUseCompoundFile ( ) { } public TieredMergePolicy setNoCFSRatio ( double noCFSRatio ) { } public double getNoCFSRatio ( ) { } private class SegmentByteSizeDescending implements Comparator < SegmentInfo > { public int compare ( SegmentInfo o1 , SegmentInfo o2 ) { } } private final Comparator < SegmentInfo > segmentByteSizeDescending = new TieredMergePolicy . SegmentByteSizeDescending ( ) ; protected abstract static class MergeScore { abstract double getScore ( ) { } abstract String getExplanation ( ) { } } @ Override public MergeSpecification findMerges ( SegmentInfos infos ) throws IOException { } protected TieredMergePolicy . MergeScore score ( List < SegmentInfo > candidate , boolean hitTooLarge , long mergingBytes ) throws IOException { } @ Override public MergeSpecification findForcedMerges ( SegmentInfos infos , int maxSegmentCount , Map < SegmentInfo , Boolean > segmentsToMerge ) throws IOException { } @ Override public MergeSpecification findForcedDeletesMerges ( SegmentInfos infos ) throws IOException , CorruptIndexException { } @ Override public boolean useCompoundFile ( SegmentInfos infos , SegmentInfo mergedInfo ) throws IOException { } @ Override public void close ( ) { } private boolean isMerged ( SegmentInfo info ) throws IOException { } private long size ( SegmentInfo info ) throws IOException { } private long floorSize ( long bytes ) { } private boolean verbose ( ) { } private void message ( String message ) { } @ Override public String toString ( ) { } }

Fix:
return ( floorSegmentBytes ) // ( 1024 * 1024.0 ) ;
Buggy code:
public class SourceIndexer extends AbstractIndexer implements SuffixConstants { public SourceIndexer ( SearchDocument document ) { } public void indexDocument ( ) { SourceIndexerRequestor requestor = new SourceIndexerRequestor ( this ) ; String documentPath = this . document . getPath ( ) ; SourceElementParser parser = ( ( InternalSearchDocument ) ( this . document ) ) . parser ; if ( parser == null ) { IPath path = new Path ( documentPath ) ; IProject project = ResourcesPlugin . getWorkspace ( ) . getRoot ( ) . getProject ( path . segment ( 0 ) ) ; parser = JavaModelManager . getJavaModelManager ( ) . indexManager . getSourceElementParser ( JavaCore . create ( project ) , requestor ) ; } else { parser . requestor = requestor ; } char [ ] source = null ; char [ ] name = null ; try { source = document . getCharContents ( ) ; name = documentPath . toCharArray ( ) ; } catch ( Exception e ) { } if ( ( source == null ) || ( name == null ) ) return ; CompilationUnit compilationUnit = new CompilationUnit ( source , name ) ; try { <START_BUG> parser . parseCompilationUnit ( compilationUnit , true ) ; <END_BUG> } catch ( Exception e ) { if ( JobManager . VERBOSE ) { e . printStackTrace ( ) ; } } } }

Fix:
parser . parseCompilationUnit ( compilationUnit , true , null ) ;
Buggy code:
public class ServletWebRequest extends WebRequest { private final HttpServletRequest httpServletRequest ; private static final Logger log = LoggerFactory . getLogger ( ServletWebRequest . class ) ; public ServletWebRequest ( final HttpServletRequest httpServletRequest ) { } @ Override public String getContextPath ( ) { } @ Override public Locale getLocale ( ) { } @ Override public String getParameter ( final String key ) { } @ Override public Map < String , Object > getParameterMap ( ) { } @ Override public String [ ] getParameters ( final String key ) { } @ Override public String getPath ( ) { } @ Override public String getServletPath ( ) { } @ Override public final HttpServletRequest getHttpServletRequest ( ) { } @ Override public String getRelativeURL ( ) { <START_BUG> String url = httpServletRequest . getServletPath ( ) ; <END_BUG> final String pathInfo = httpServletRequest . getPathInfo ( ) ; if ( pathInfo != null ) { url += pathInfo ; } final String queryString = httpServletRequest . getQueryString ( ) ; if ( queryString != null ) { url += "?" + queryString ; } if ( ! ( url . equals ( "" ) ) ) { url = url . substring ( 1 ) ; } url = Strings . stripJSessionId ( url ) ; return url ; } @ Override public String toString ( ) { } @ Override public WebRequest newMultipartWebRequest ( Bytes maxsize ) { } @ Override public boolean isAjax ( ) { } public boolean mergeVersion ( ) { } }

Fix:
String url = getServletPath ( ) ;
Buggy code:
@ SuppressWarnings ( { "deprecation" , "unchecked" } ) public class TasksDaoImpl extends AbstractDao implements TasksDao { @ Override public Serializable saveTask ( Task task ) { } @ Override public void updateTask ( Task task ) { } @ Override public void saveOrUpdateTaskStatus ( Task task , Date taskStatusDate ) { } @ Override public void deleteTask ( Task task , Date taskStatusDate ) { } @ Override public List < Task > tasksOfDate ( Date date , Boolean deleteStatus ) { } private void updateTasksStatusAndDuration ( List < Task > list , Date date , Session session ) { } private TaskStatus statusOfTask ( Task task , Date selectedDate , Session session ) { } private List < TaskStatus > getTaskStatusOfTask ( Task task , Session session ) { } @ Override public List < Task > searchTasks ( String searchText ) { try { session = sessionFactory . openSession ( ) ; Criteria criteria = session . createCriteria ( Task . class ) ; Criterion criterion1 = Expression . ilike ( "description" , ( ( "%" + searchText ) + "%" ) ) ; <START_BUG> criteria . add ( criterion1 ) . add ( criterion1 ) ; <END_BUG> List < Task > list = criteria . list ( ) ; return list ; } finally { if ( ( ( session ) != null ) && ( session . isOpen ( ) ) ) session . close ( ) ; } } @ Override public List < TasksChart > getTasksReportData ( Integer selectedYear ) { } No newline ; at end ; of file ; }

Fix:
criteria . add ( criterion1 ) ;
Buggy code:
public class AntPathMatcher implements PathMatcher { public static final String DEFAULT_PATH_SEPARATOR = "//" ; private String pathSeparator = AntPathMatcher . DEFAULT_PATH_SEPARATOR ; public void setPathSeparator ( String pathSeparator ) { } public boolean isPattern ( String path ) { } public boolean match ( String pattern , String path ) { } public boolean matchStart ( String pattern , String path ) { } protected boolean doMatch ( String pattern , String path , boolean fullMatch , Map < String , String > uriTemplateVariables ) { } private boolean matchStrings ( String pattern , String str , Map < String , String > uriTemplateVariables ) { } public String extractPathWithinPattern ( String pattern , String path ) { } public Map < String , String > extractUriTemplateVariables ( String pattern , String path ) { } public String combine ( String pattern1 , String pattern2 ) { } public Comparator < String > getPatternComparator ( String path ) { } private static class AntPatternComparator implements Comparator < String > { private final String path ; private AntPatternComparator ( String path ) { } public int compare ( String pattern1 , String pattern2 ) { if ( ( pattern1 == null ) && ( pattern2 == null ) ) { return 0 ; } else if ( pattern1 == null ) { return 1 ; } else if ( pattern2 == null ) { return - 1 ; } boolean pattern1EqualsPath = pattern1 . equals ( path ) ; boolean pattern2EqualsPath = pattern2 . equals ( path ) ; if ( pattern1EqualsPath && pattern2EqualsPath ) { return 0 ; } else if ( pattern1EqualsPath ) { return - 1 ; } else if ( pattern2EqualsPath ) { return 1 ; } int wildCardCount1 = StringUtils . countOccurrencesOf ( pattern1 , "*" ) ; int wildCardCount2 = StringUtils . countOccurrencesOf ( pattern2 , "*" ) ; if ( wildCardCount1 < wildCardCount2 ) { return - 1 ; } else if ( wildCardCount2 < wildCardCount1 ) { return 1 ; } int bracketCount1 = StringUtils . countOccurrencesOf ( pattern1 , "{" ) ; int bracketCount2 = StringUtils . countOccurrencesOf ( pattern2 , "{" ) ; if ( bracketCount1 < bracketCount2 ) { return - 1 ; } else <START_BUG> if ( bracketCount1 < bracketCount2 ) { <END_BUG> return 1 ; } return 0 ; } } }

Fix:
if ( bracketCount2 < bracketCount1 ) {
Buggy code:
public class QRSolverTest extends TestCase { double [ ] [ ] testData3x3NonSingular = new double [ ] [ ] { new double [ ] { 12 , - 51 , 4 } , new double [ ] { 6 , 167 , - 68 } , new double [ ] { - 4 , 24 , - 41 } } ; double [ ] [ ] testData3x3Singular = new double [ ] [ ] { new double [ ] { 1 , 4 , 7 } , new double [ ] { 2 , 5 , 8 } , new double [ ] { 3 , 6 , 9 } } ; double [ ] [ ] testData3x4 = new double [ ] [ ] { new double [ ] { 12 , - 51 , 4 , 1 } , new double [ ] { 6 , 167 , - 68 , 2 } , new double [ ] { - 4 , 24 , - 41 , 3 } } ; double [ ] [ ] testData4x3 = new double [ ] [ ] { new double [ ] { 12 , - 51 , 4 } , new double [ ] { 6 , 167 , - 68 } , new double [ ] { - 4 , 24 , - 41 } , new double [ ] { - 5 , 34 , 7 } } ; public QRSolverTest ( String name ) { } public static Test suite ( ) { } public void testRank ( ) { QRSolver solver = new QRSolver ( new QRDecompositionImpl ( MatrixUtils . createRealMatrix ( testData3x3NonSingular ) ) ) ; assertTrue ( solver . isNonSingular ( ) ) ; solver = new QRSolver ( new QRDecompositionImpl ( MatrixUtils . createRealMatrix ( testData3x3Singular ) ) ) ; assertFalse ( solver . isNonSingular ( ) ) ; solver = new QRSolver ( new QRDecompositionImpl ( MatrixUtils . createRealMatrix ( testData3x4 ) ) ) ; <START_BUG> assertTrue ( solver . isNonSingular ( ) ) ; <END_BUG> solver = new QRSolver ( new QRDecompositionImpl ( MatrixUtils . createRealMatrix ( testData4x3 ) ) ) ; assertTrue ( solver . isNonSingular ( ) ) ; } public void testSolveDimensionErrors ( ) { } public void testSolveRankErrors ( ) { } public void testSolve ( ) { } }

Fix:
assertFalse ( solver . isNonSingular ( ) ) ;
Buggy code:
public class CopydirTest extends TaskdefsTest { public CopydirTest ( String name ) { } public void setUp ( ) { } public void test1 ( ) { } public void test2 ( ) { } public void test3 ( ) { } public void test4 ( ) { <START_BUG> expectLog ( "test4" , "Warning:<seq2seq4repair_space>src<seq2seq4repair_space>==<seq2seq4repair_space>dest" ) ; <END_BUG> } public void test5 ( ) { } public void test6 ( ) { } }

Fix:
expectLog ( "test4" , "DEPRECATED<seq2seq4repair_space>-<seq2seq4repair_space>The<seq2seq4repair_space>copydir<seq2seq4repair_space>task<seq2seq4repair_space>is<seq2seq4repair_space>deprecated.<seq2seq4repair_space>Use<seq2seq4repair_space>copy<seq2seq4repair_space>instead.Warning:<seq2seq4repair_space>src<seq2seq4repair_space>==<seq2seq4repair_space>dest" ) ;
Buggy code:
public final class FieldCacheSanityChecker { private RamUsageEstimator ramCalc = null ; public FieldCacheSanityChecker ( ) { } public void setRamUsageEstimator ( RamUsageEstimator r ) { } public static FieldCacheSanityChecker . Insanity [ ] checkSanity ( FieldCache cache ) { } public static FieldCacheSanityChecker . Insanity [ ] checkSanity ( CacheEntry ... cacheEntries ) { } public FieldCacheSanityChecker . Insanity [ ] check ( CacheEntry ... cacheEntries ) { } private Collection < FieldCacheSanityChecker . Insanity > checkValueMismatch ( MapOfSets < Integer , CacheEntry > valIdToItems , MapOfSets < FieldCacheSanityChecker . ReaderField , Integer > readerFieldToValIds , Set < FieldCacheSanityChecker . ReaderField > valMismatchKeys ) { } private Collection < FieldCacheSanityChecker . Insanity > checkSubreaders ( MapOfSets < Integer , CacheEntry > valIdToItems , MapOfSets < FieldCacheSanityChecker . ReaderField , Integer > readerFieldToValIds ) { } private List < Object > getAllDecendentReaderKeys ( Object seed ) { List < Object > all = new ArrayList < Object > ( 17 ) ; all . add ( seed ) ; for ( int i = 0 ; i < ( all . size ( ) ) ; i ++ ) { Object obj = all . get ( i ) ; if ( obj instanceof IndexReader ) { IndexReader [ ] subs = ( ( IndexReader ) ( obj ) ) . getSequentialSubReaders ( ) ; for ( int j = 0 ; ( null != subs ) && ( j < ( subs . length ) ) ; j ++ ) { <START_BUG> all . add ( subs [ j ] . getFieldCacheKey ( ) ) ; <END_BUG> } } } return all . subList ( 1 , all . size ( ) ) ; } private static final class ReaderField { public final Object readerKey ; public final String fieldName ; public ReaderField ( Object readerKey , String fieldName ) { } @ Override public int hashCode ( ) { } @ Override public boolean equals ( Object that ) { } @ Override public String toString ( ) { } } public static final class Insanity { private final FieldCacheSanityChecker . InsanityType type ; private final String msg ; private final CacheEntry [ ] entries ; public Insanity ( FieldCacheSanityChecker . InsanityType type , String msg , CacheEntry ... entries ) { } public FieldCacheSanityChecker . InsanityType getType ( ) { } public String getMsg ( ) { } public CacheEntry [ ] getCacheEntries ( ) { } @ Override public String toString ( ) { } } public static final class InsanityType { private final String label ; private InsanityType ( final String label ) { } @ Override public String toString ( ) { } public static final FieldCacheSanityChecker . InsanityType SUBREADER = new FieldCacheSanityChecker . InsanityType ( "SUBREADER" ) ; public static final FieldCacheSanityChecker . InsanityType VALUEMISMATCH = new FieldCacheSanityChecker . InsanityType ( "VALUEMISMATCH" ) ; public static final FieldCacheSanityChecker . InsanityType EXPECTED = new FieldCacheSanityChecker . InsanityType ( "EXPECTED" ) ; } }

Fix:
all . add ( subs [ j ] . getCoreCacheKey ( ) ) ;
Buggy code:
class OperationTransformationOverrideBuilderImpl extends AttributeTransformationDescriptionBuilderImpl implements OperationTransformationOverrideBuilder { private boolean inherit = false ; private DiscardPolicy discardPolicy = DiscardPolicy . NEVER ; private OperationTransformer transformer = OperationTransformer . DEFAULT ; private String newName ; protected OperationTransformationOverrideBuilderImpl ( ResourceTransformationDescriptionBuilder builder ) { } @ Override public OperationTransformationOverrideBuilder inherit ( ) { } public OperationTransformationOverrideBuilder setOperationTransformer ( OperationTransformer transformer ) { } @ Override public OperationTransformationOverrideBuilder rename ( String newName ) { } protected OperationTransformer createTransformer ( final AttributeTransformationDescriptionBuilderRegistry resourceRegistry ) { final AttributeTransformationDescriptionBuilderRegistry registry = resultingRegistry ( resourceRegistry ) ; final AttributeTransformationRule first = new AttributeTransformationRule ( registry . buildAttributes ( ) ) ; return new OperationTransformer ( ) { @ Override public TransformedOperation transformOperation ( final TransformationContext ctx , final PathAddress address , final ModelNode operation ) throws OperationFailedException { if ( discardPolicy . discard ( operation , address , ctx ) ) { return DISCARD . transformOperation ( ctx , address , operation ) ; } final Iterator < TransformationRule > iterator = Collections . < TransformationRule > emptyList ( ) . iterator ( ) ; final ModelNode originalModel = operation . clone ( ) ; originalModel . protect ( ) ; <START_BUG> final TransformationRule . OperationContext context = new TransformationRule . OperationContext ( ctx , originalModel ) { <END_BUG> @ Override void invokeNext ( OperationTransformer . TransformedOperation transformedOperation ) throws OperationFailedException { recordTransformedOperation ( transformedOperation ) ; if ( iterator . hasNext ( ) ) { final TransformationRule next = iterator . next ( ) ; next . transformOperation ( transformedOperation . getTransformedOperation ( ) , address , this ) ; } else { if ( ( newName ) != null ) { transformedOperation . getTransformedOperation ( ) . get ( OP ) . set ( newName ) ; } final TransformationContext ctx = getContext ( ) ; transformer . transformOperation ( ctx , address , transformedOperation . getTransformedOperation ( ) ) ; } } } ; operation . get ( OP_ADDR ) . set ( address . toModelNode ( ) ) ; first . transformOperation ( operation , address , context ) ; return context . createOp ( ) ; } } ; } protected AttributeTransformationDescriptionBuilderRegistry resultingRegistry ( final AttributeTransformationDescriptionBuilderRegistry resourceRegistry ) { } }

Fix:
final TransformationRule . OperationContext context = new TransformationRule . OperationContext ( ctx ) {
Buggy code:
public class ObjectFactoryBuilder implements ObjectFactory , javax . naming . spi . ObjectFactoryBuilder { public ObjectFactory createObjectFactory ( final Object obj , Hashtable < ? , ? > environment ) throws NamingException { } public Object getObjectInstance ( final Object obj , final Name name , final Context nameCtx , final Hashtable < ? , ? > environment ) throws Exception { } private ObjectFactory factoryFromReference ( final Reference reference , final Hashtable < ? , ? > environment ) throws NamingException { } private ObjectFactory factoryFromModularReference ( ModularReference modularReference ) throws NamingException { try { <START_BUG> final Module module = Module . getModule ( ModuleIdentifier . fromString ( modularReference . getModuleName ( ) ) ) ; <END_BUG> final Class < ? > factoryClass = module . getClassLoader ( ) . loadClass ( modularReference . getFactoryClassName ( ) ) ; return ObjectFactory . class . cast ( factoryClass . newInstance ( ) ) ; } catch ( Throwable t ) { throw namingException ( "Failed<seq2seq4repair_space>to<seq2seq4repair_space>create<seq2seq4repair_space>object<seq2seq4repair_space>factory<seq2seq4repair_space>from<seq2seq4repair_space>modular<seq2seq4repair_space>reference." , t ) ; } } private ClassLoader getContextClassLoader ( ) { } }

Fix:
final Module module = Module . getModule ( modularReference . getModuleIdentifier ( ) ) ;
Buggy code:
public class DependencyInfo implements Comparable < DependencyInfo > { private static final Logger LOGGER = Logger . getLogger ( DependencyInfo . class ) ; private File file ; private Set < String > provides ; private Set < String > requires ; private Set < String > namespaces ; public DependencyInfo ( final File parsedFile ) { } public final String toDepsString ( final File basePath ) throws IOException { } public final String toRequiresString ( final File basePath ) throws IOException { StringBuilder providesString = new StringBuilder ( ) ; for ( String provide : getProvides ( ) ) { <START_BUG> providesString . append ( "goog.requires(\"" ) ; <END_BUG> providesString . append ( provide ) ; providesString . append ( "\");\n" ) ; } return providesString . toString ( ) ; } public final void addToProvides ( final String namespace ) { } public final void addToRequires ( final String namespace ) { } public final File getFile ( ) { } public final String getFilename ( ) { } public final Collection < String > getProvides ( ) { } public final String getProvidesString ( ) { } public final Collection < String > getRequires ( ) { } public final String getRequiresString ( ) { } @ Override public final int compareTo ( final DependencyInfo o ) { } public final void addToNamespaces ( final String namespace ) { } public final String getNamespaceString ( ) { } public final Set < String > getNamespaces ( ) { } }

Fix:
providesString . append ( "goog.require(\"" ) ;
Buggy code:
public final class MutableContextManager extends AbstractContextManager implements IMutableContextManager { static boolean isContextDefinitionChildOf ( String ancestor , String id , Map contextDefinitionsById ) { } private Map contextContextBindingsByParentContextId = new HashMap ( ) ; private Map contextDefinitionsById = new HashMap ( ) ; private IContextRegistry contextRegistry ; private Map contextsById = new WeakHashMap ( ) ; private Set definedContextIds = new HashSet ( ) ; private Set enabledContextIds = new HashSet ( ) ; public MutableContextManager ( ) { } public MutableContextManager ( IContextRegistry contextRegistry ) { } public IContext getContext ( String contextId ) { } public Set getDefinedContextIds ( ) { } public Set getEnabledContextIds ( ) { } private void getRequiredContextIds ( Set contextIds , Set requiredContextIds ) { } private void notifyContexts ( Map contextEventsByContextId ) { } private void readRegistry ( ) { } public void setEnabledContextIds ( Set enabledContextIds ) { enabledContextIds = Util . safeCopy ( enabledContextIds , String . class ) ; Set requiredContextIds = new HashSet ( enabledContextIds ) ; getRequiredContextIds ( enabledContextIds , requiredContextIds ) ; enabledContextIds = requiredContextIds ; boolean contextManagerChanged = false ; Map contextEventsByContextId = null ; if ( ! ( this . enabledContextIds . equals ( enabledContextIds ) ) ) { this . enabledContextIds = enabledContextIds ; contextManagerChanged = true ; <START_BUG> contextEventsByContextId = updateContexts ( this . definedContextIds ) ; <END_BUG> } if ( contextManagerChanged ) fireContextManagerChanged ( new ContextManagerEvent ( this , false , true ) ) ; if ( contextEventsByContextId != null ) notifyContexts ( contextEventsByContextId ) ; } private ContextEvent updateContext ( Context context ) { } private Map updateContexts ( Collection contextIds ) { } }

Fix:
contextEventsByContextId = updateContexts ( contextsById . keySet ( ) ) ;
Buggy code:
public class Procedure implements Cloneable { private String name ; private Map < String , IVariable > varList ; private Map < String , Construct > originals = new HashMap < String , Construct > ( ) ; private List < IVariable > varIndex = new ArrayList < IVariable > ( ) ; private GenericTreeNode < Construct > tree ; public Procedure ( String name , List < IVariable > varList , GenericTreeNode < Construct > tree , CFunction f ) { } public String getName ( ) { } @ Override public String toString ( ) { } public Construct cexecute ( List < GenericTreeNode < Construct > > args , Env env ) { } public Construct execute ( List < Construct > args , Env env ) { env . SetVarList ( new IVariableList ( ) ) ; CArray array = new CArray ( 0 , null ) ; for ( String key : originals . keySet ( ) ) { Construct c = originals . get ( key ) ; env . GetVarList ( ) . set ( new IVariable ( key , c , 0 , null ) ) ; array . push ( c ) ; } GenericTree < Construct > root = new GenericTree < Construct > ( ) ; root . setRoot ( tree ) ; <START_BUG> Script fakeScript = new Script ( null , null , env ) ; <END_BUG> for ( int i = 0 ; i < ( args . size ( ) ) ; i ++ ) { Construct c = args . get ( i ) ; array . set ( i , c ) ; if ( ( varIndex . size ( ) ) > i ) { String varname = varIndex . get ( i ) . getName ( ) ; env . GetVarList ( ) . set ( new IVariable ( varname , c , c . getLineNum ( ) , c . getFile ( ) ) ) ; } } env . GetVarList ( ) . set ( new IVariable ( "@arguments" , array , 0 , null ) ) ; try { fakeScript . eval ( tree , env ) ; } catch ( FunctionReturnException e ) { return e . getReturn ( ) ; } return new CVoid ( 0 , null ) ; } @ Override public Procedure clone ( ) throws CloneNotSupportedException { } }

Fix:
Script fakeScript = new Script ( null , null ) ;
Buggy code:
public class FastVectorHighlighterTest extends SolrTestCaseJ4 { @ BeforeClass public static void beforeClass ( ) throws Exception { } @ Test public void testConfig ( ) { } @ Test public void test ( ) { HashMap < String , String > args = new HashMap < String , String > ( ) ; args . put ( "hl" , "true" ) ; args . put ( "hl.fl" , "tv_text" ) ; args . put ( "hl.snippets" , "2" ) ; args . put ( "hl.useFastVectorHighlighter" , "true" ) ; TestHarness . LocalRequestFactory sumLRF = h . getRequestFactory ( "standard" , 0 , 200 , args ) ; assertU ( adoc ( "tv_text" , "basic<seq2seq4repair_space>fast<seq2seq4repair_space>vector<seq2seq4repair_space>highlighter<seq2seq4repair_space>test" , "id" , "1" ) ) ; assertU ( commit ( ) ) ; assertU ( optimize ( ) ) ; <START_BUG> assertQ ( "Basic<seq2seq4repair_space>summarization" , sumLRF . makeRequest ( "tv_text:vector" ) , "////lst[@name='highlighting']//lst[@name='1']" , "////lst[@name='1']//arr[@name='tv_text']//str[.='<seq2seq4repair_space>fast<seq2seq4repair_space><em>vector<//em><seq2seq4repair_space>highlighter<seq2seq4repair_space>test']" ) ; <END_BUG> } }

Fix:
assertQ ( "Basic<seq2seq4repair_space>summarization" , sumLRF . makeRequest ( "tv_text:vector" ) , "////lst[@name='highlighting']//lst[@name='1']" , "////lst[@name='1']//arr[@name='tv_text']//str[.='basic<seq2seq4repair_space>fast<seq2seq4repair_space><em>vector<//em><seq2seq4repair_space>highlighter<seq2seq4repair_space>test']" ) ;
Buggy code:
@ RunWith ( JUnit4TestRunner . class ) public class BlueprintContainerTest extends AbstractIntegrationTest { @ Test public void test ( ) throws Exception { } @ Test public void testReferenceListenerDeadlock ( ) throws Exception { } private InputStream getTestBundle ( int no , int total ) throws Exception { } @ Test public void testDeadlock ( ) throws Exception { } @ Test public void testScheduledExecMemoryLeak ( ) throws Exception { Fixture jar = ArchiveFixture . newJar ( ) . manifest ( ) . symbolicName ( "test.bundle" ) . end ( ) . file ( "OSGI-INF//blueprint//blueprint.xml" ) . line ( "<blueprint<seq2seq4repair_space>xmlns=\"http:////www.osgi.org//xmlns//blueprint//v1.0.0\">" ) . line ( "<reference<seq2seq4repair_space>interface=\"java.util.List\"<seq2seq4repair_space>//>" ) . line ( "<//blueprint>" ) . end ( ) . end ( ) ; ByteArrayOutputStream bout = new ByteArrayOutputStream ( ) ; jar . writeOut ( bout ) ; Bundle b = bundleContext . installBundle ( "test.bundle" , new ByteArrayInputStream ( bout . toByteArray ( ) ) ) ; for ( int i = 0 ; i < 16 ; i ++ ) System . gc ( ) ; long startFreeMemory = Runtime . getRuntime ( ) . freeMemory ( ) ; for ( int i = 0 ; i < 3000 ; i ++ ) { b . start ( ) ; Thread . sleep ( 10 ) ; b . stop ( ) ; } for ( int i = 0 ; i < 16 ; i ++ ) System . gc ( ) ; long endFreeMemory = Runtime . getRuntime ( ) . freeMemory ( ) ; long lossage = startFreeMemory - endFreeMemory ; <START_BUG> assertTrue ( ( "We<seq2seq4repair_space>lost:<seq2seq4repair_space>" + lossage ) , ( lossage < 10000000 ) ) ; <END_BUG> } @ org . ops4j . pax . exam . junit . Configuration public static Option [ ] configuration ( ) { } }

Fix:
assertTrue ( ( "We<seq2seq4repair_space>lost:<seq2seq4repair_space>" + lossage ) , ( lossage < 20000000 ) ) ;
Buggy code:
final class R_OSGiRemoteServiceContainer implements IContainer , IRemoteServiceContainerAdapter , RemoteServiceListener { private BundleContext context ; private RemoteOSGiService remoteService ; private ChannelEndpointManager endpointMgr ; private final List containerListeners = new ArrayList ( 0 ) ; R_OSGiID containerID ; private R_OSGiID connectedID ; private ServiceTracker remoteServicesTracker ; private Map remoteServicesRegs = new HashMap ( 0 ) ; private Map remoteServiceListeners = new HashMap ( 0 ) ; public R_OSGiRemoteServiceContainer ( ) throws IDCreateException { } public R_OSGiRemoteServiceContainer ( final ID containerID ) throws IDCreateException { } private void startRegTracker ( ) { } public void addRemoteServiceListener ( final IRemoteServiceListener listener ) { } public IRemoteService getRemoteService ( final IRemoteServiceReference reference ) { } public IRemoteServiceReference [ ] getRemoteServiceReferences ( final ID [ ] idFilter , final String clazz , final String filter ) throws InvalidSyntaxException { } public IRemoteServiceRegistration registerRemoteService ( final String [ ] clazzes , final Object service , final Dictionary properties ) { } public void removeRemoteServiceListener ( final IRemoteServiceListener listener ) { } public boolean ungetRemoteService ( IRemoteServiceReference reference ) { } public Object getAdapter ( final Class adapter ) { } public void addListener ( final IContainerListener listener ) { } public void connect ( final ID targetID , final IConnectContext connectContext ) throws ContainerConnectException { } public void disconnect ( ) { } public void dispose ( ) { } public Namespace getConnectNamespace ( ) { } public ID getConnectedID ( ) { } public void removeListener ( final IContainerListener listener ) { } public ID getID ( ) { } private void fireListeners ( final IContainerEvent event ) { } public void remoteServiceEvent ( final RemoteServiceEvent event ) { } private void checkImport ( final RemoteServiceReference ref ) { } private Hashtable clone ( final Dictionary props ) { } <START_BUG> public IFutureStatus asyncGetRemoteServiceReferences ( final ID [ ] idFilter , final String clazz , final String filter ) { <END_BUG> IProgressRunnable fc = new IProgressRunnable ( ) { public Object run ( IProgressMonitor monitor ) throws Throwable { return getRemoteServiceReferences ( idFilter , clazz , filter ) ; } } ; FutureStatus future = new FutureStatus ( ) ; Thread t = new Thread ( future . setter ( fc ) , NLS . bind ( "Get<seq2seq4repair_space>remote<seq2seq4repair_space>reference<seq2seq4repair_space>for<seq2seq4repair_space>{0}" , clazz ) ) ; t . start ( ) ; return future ; } public Namespace getRemoteServiceNamespace ( ) { } public IRemoteFilter createRemoteFilter ( String filter ) throws InvalidSyntaxException { } }

Fix:
public IFuture asyncGetRemoteServiceReferences ( final ID [ ] idFilter , final String clazz , final String filter ) {
Buggy code:
public class AuthenticatorManager { private static Log log = LogFactory . getLog ( AuthenticatorManager . class ) ; private static AuthenticatorManager manager ; private HashMap authenticators = new HashMap ( ) ; UserCache userCache ; boolean singleUserAccess = true ; private AuthenticatorManager ( ) { } public static AuthenticatorManager getInstance ( ) { } public void addAuthenticator ( String publicationName , Authenticator authenticator ) { } private Authenticator getAuthenticator ( String publicationName ) { } public UserCache getUserCache ( ) { } public void setUserCache ( UserCache userCache ) { } public boolean isSingleUserAccess ( ) { } public void setSingleUserAccess ( boolean singleUserAccess ) { } public String [ ] getCookieNames ( ) { } public AuthenticatedUser authenticate ( String publicationName , String username , String password , String ipaddress ) { } public AuthenticatedUser authenticateUsingToken ( String publicationName , String token ) { } public AuthenticatedUser getUserFromCookie ( String publicationName , Cookie [ ] cookies ) { } private boolean addUserToCache ( AuthenticatedUser user ) { } public boolean passwordReminder ( String publicationName , String emailAddress ) { } public void register ( String publicationName , String username , String password , String postalCode , String customerNumber ) throws RegistrationException { } public AuthenticatedUser authenticateAuto ( String authenticatorName , String encryptedUserInfo , String ipadress ) { } public Collection getLoggedInUsers ( ) { } public void evictUser ( String token ) { } public void evictUser ( String publicationName , String token ) { } public AuthenticatedUser getUser ( String token ) { <START_BUG> if ( token == null ) { <END_BUG> return null ; } return userCache . getUser ( token ) ; } public boolean userHasBeenEvicted ( String token ) { } public String getCookieName ( String publicationName ) { } public String getAutoLoginCookieName ( String publicationName ) { } public Cookie getSessionCookie ( String publicationName , String token ) { } public Cookie getAutologinCookie ( String publicationName , String userName , String password ) { } public Cookie removeSessionCookie ( String publicationName ) { } public Cookie removeAutologinCookie ( String publicationName ) { } public static String getRemoteAddress ( HttpServletRequest request ) { } public boolean changePassword ( String publicationName , AuthenticatedUser user , String oldPassword , String newPassword ) { } }

Fix:
if ( ( token == null ) || ( token == "" ) ) {
Buggy code:
public class KernelStatementTest { @ Test public void shouldCloseOpenedLabelScanReader ( ) throws Exception { } @ Test ( expected = TransactionTerminatedException . class ) public void shouldThrowTerminateExceptionWhenTransactionTerminated ( ) throws Exception { } @ Test public void shouldCloseOpenedLabelScanReaderWhenForceClosed ( ) throws Exception { LabelScanStore scanStore = mock ( LabelScanStore . class ) ; LabelScanReader scanReader = mock ( LabelScanReader . class ) ; when ( scanStore . newReader ( ) ) . thenReturn ( scanReader ) ; <START_BUG> KernelStatement statement = new KernelStatement ( mock ( KernelTransactionImplementation . class ) , mock ( IndexReaderFactory . class ) , scanStore , null , null , null , null ) ; <END_BUG> statement . acquire ( ) ; LabelScanReader actualReader = statement . getLabelScanReader ( ) ; assertEquals ( scanReader , actualReader ) ; statement . forceClose ( ) ; verify ( scanStore ) . newReader ( ) ; verifyNoMoreInteractions ( scanStore ) ; verify ( scanReader ) . close ( ) ; verifyNoMoreInteractions ( scanReader ) ; } }

Fix:
KernelStatement statement = new KernelStatement ( mock ( KernelTransactionImplementation . class ) , mock ( IndexReaderFactory . class ) , scanStore , null , null , null ) ;
Buggy code:
public class JavaSearchParticipant extends SearchParticipant { IndexSelector indexSelector ; public void beginSearching ( ) { } public void doneSearching ( ) { } public String getDescription ( ) { } public SearchDocument getDocument ( String documentPath ) { } public void indexDocument ( SearchDocument document , IPath indexPath ) { <START_BUG> removeAllIndexEntries ( document ) ; <END_BUG> String documentPath = document . getPath ( ) ; if ( Util . isJavaFileName ( documentPath ) ) { new SourceIndexer ( document ) . indexDocument ( ) ; } else if ( Util . isClassFileName ( documentPath ) ) { new BinaryIndexer ( document ) . indexDocument ( ) ; } } public void locateMatches ( SearchDocument [ ] indexMatches , SearchPattern pattern , IJavaSearchScope scope , SearchRequestor requestor , IProgressMonitor monitor ) throws CoreException { } public IPath [ ] selectIndexes ( SearchPattern pattern , IJavaSearchScope scope ) { } }

Fix:
document . removeAllIndexEntries ( ) ;
Buggy code:
public class TestBooleanQueryVisitSubscorers extends LuceneTestCase { Analyzer analyzer ; IndexReader reader ; IndexSearcher searcher ; Directory dir ; static final String F1 = "title" ; static final String F2 = "body" ; @ Override public void setUp ( ) throws Exception { super . setUp ( ) ; analyzer = new org . apache . lucene . analysis . MockAnalyzer ( random ( ) ) ; dir = newDirectory ( ) ; IndexWriterConfig config = newIndexWriterConfig ( TEST_VERSION_CURRENT , analyzer ) ; config . setMergePolicy ( newLogMergePolicy ( ) ) ; RandomIndexWriter writer = new RandomIndexWriter ( random ( ) , dir , config ) ; writer . addDocument ( TestBooleanQueryVisitSubscorers . doc ( "lucene" , "lucene<seq2seq4repair_space>is<seq2seq4repair_space>a<seq2seq4repair_space>very<seq2seq4repair_space>popular<seq2seq4repair_space>search<seq2seq4repair_space>engine<seq2seq4repair_space>library" ) ) ; writer . addDocument ( TestBooleanQueryVisitSubscorers . doc ( "solr" , "solr<seq2seq4repair_space>is<seq2seq4repair_space>a<seq2seq4repair_space>very<seq2seq4repair_space>popular<seq2seq4repair_space>search<seq2seq4repair_space>server<seq2seq4repair_space>and<seq2seq4repair_space>is<seq2seq4repair_space>using<seq2seq4repair_space>lucene" ) ) ; writer . addDocument ( TestBooleanQueryVisitSubscorers . doc ( "nutch" , "nutch<seq2seq4repair_space>is<seq2seq4repair_space>an<seq2seq4repair_space>internet<seq2seq4repair_space>search<seq2seq4repair_space>engine<seq2seq4repair_space>with<seq2seq4repair_space>web<seq2seq4repair_space>crawler<seq2seq4repair_space>and<seq2seq4repair_space>is<seq2seq4repair_space>using<seq2seq4repair_space>lucene<seq2seq4repair_space>and<seq2seq4repair_space>hadoop" ) ) ; reader = writer . getReader ( ) ; <START_BUG> writer . close ( ) ; <END_BUG> searcher = newSearcher ( reader ) ; } @ Override public void tearDown ( ) throws Exception { } public void testDisjunctions ( ) throws IOException { } public void testNestedDisjunctions ( ) throws IOException { } public void testConjunctions ( ) throws IOException { } static Document doc ( String v1 , String v2 ) { } static Map < Integer , Integer > getDocCounts ( IndexSearcher searcher , Query query ) throws IOException { } static class MyCollector extends FilterCollector { public final Map < Integer , Integer > docCounts = new HashMap < > ( ) ; private final Set < Scorer > tqsSet = new HashSet < > ( ) ; MyCollector ( ) { } public LeafCollector getLeafCollector ( AtomicReaderContext context ) throws IOException { } private void fillLeaves ( Scorer scorer , Set < Scorer > set ) { } public TopDocs topDocs ( ) { } public int freq ( int doc ) throws IOException { } } }

Fix:
writer . shutdown ( ) ;
Buggy code:
public class ResourceReader implements Closeable { private static final ClassLoader classLoader = Thread . currentThread ( ) . getContextClassLoader ( ) ; private final Map < String , String [ ] > map = new HashMap < String , String [ ] > ( ) ; private final ResourceParser resourceParser ; private final String filename ; private String delimiterField ; private Map . Entry < String , String > entry ; public ResourceReader ( String filename ) { } public boolean readNextElement ( ) { } private void addToMap ( String key , String value ) { } private String [ ] toArray ( String data ) { if ( data . startsWith ( "[" ) ) { <START_BUG> data = data . substring ( 1 , data . length ( ) ) ; <END_BUG> return Utils . split ( data , "|" ) ; } else { return new String [ ] { data } ; } } private void readNextEntry ( ) { } private AbstractMap . SimpleEntry < String , String > makeEntryFromString ( String string ) { } public boolean hasValue ( String key ) { } public String getValue ( String key ) { } public String [ ] getArrayOfValues ( String key ) { } private void logRepeatedValue ( ) { } private void logMissingColon ( ) { } private void logMissingValue ( ) { } @ Override public void close ( ) { } }

Fix:
data = data . substring ( 1 , ( ( data . length ( ) ) - 1 ) ) ;
Buggy code:
public class Game { private static int gameNum ; private int gid ; public String name ; public HashMap < Integer , Player > playerCollection = new HashMap < Integer , Player > ( ) ; public GameBoard board = new GameBoard ( ) ; int setLock ; public Game ( ) { } public void setLock ( int uid ) { } public void resetLock ( ) { } public int lockOwner ( ) { } public int returnGid ( ) { } public String block ( int seconds ) { } public String unblock ( ) { } public String onSubmit ( int uid , int c1 , int c2 , int c3 ) throws Exception { } public String returnScoreBoard ( ) throws Exception { } public String returnScore ( int uid , int scoreChange ) throws Exception { } public String dropPlayerFromSB ( int uid ) { } public String addPlayerToSB ( int uid ) throws Exception { <START_BUG> return ( ( ( ( ( ( ( "Z" + ( gid ) ) + "`" ) + ( Integer . toString ( uid ) ) ) + "`" ) + ( playerCollection . get ( uid ) . Username ) ) + "`" ) + "0" ) + ( Integer . toString ( db . returnRating ( uid ) ) ) ; <END_BUG> } public void join ( int uid , Player player ) { } public void leave ( int uid ) { } public int playerNum ( ) { } public Player findPlayer ( int uid ) { } private void addPlayer ( int uid , Player player ) { } private void disconnectPlayer ( int uid ) { } }

Fix:
return ( ( ( ( ( ( ( "Z" + ( gid ) ) + "`" ) + ( Integer . toString ( uid ) ) ) + "`" ) + ( playerCollection . get ( uid ) . Username ) ) + "`" ) + "0`" ) + ( Integer . toString ( db . returnRating ( uid ) ) ) ;
Buggy code:
public class SolicitudesController extends SolicitudesControllerGen { protected static Logger log = Logger . getLogger ( "Paginas" ) ; public static void tablalistaSolicitudesBuscadas ( ) { } @ Util public static void busquedaFormRender ( ) { } public static void tablalistaSolicitudes ( ) { List < SolicitudGenerica > rows = new ArrayList < SolicitudGenerica > ( ) ; Agente usuario = AgenteController . getAgente ( ) ; String rolActivo = usuario . getRolActivo ( ) ; List < SolicitudGenerica > allrows = null ; if ( rolActivo . equals ( "gestorTenerife" ) ) { allrows = SolicitudGenerica . find ( "select<seq2seq4repair_space>solicitud<seq2seq4repair_space>from<seq2seq4repair_space>SolicitudGenerica<seq2seq4repair_space>solicitud<seq2seq4repair_space>where<seq2seq4repair_space>solicitud.solicitante<seq2seq4repair_space>in<seq2seq4repair_space>(select<seq2seq4repair_space>solicitante.id<seq2seq4repair_space>from<seq2seq4repair_space>Solicitante<seq2seq4repair_space>solicitante<seq2seq4repair_space>where<seq2seq4repair_space>solicitante.domicilio.provincia<seq2seq4repair_space>=<seq2seq4repair_space>'_38')" ) . fetch ( ) ; } else if ( rolActivo . equals ( "gestorLasPalmas" ) ) { allrows = SolicitudGenerica . find ( "select<seq2seq4repair_space>solicitud<seq2seq4repair_space>from<seq2seq4repair_space>SolicitudGenerica<seq2seq4repair_space>solicitud<seq2seq4repair_space>where<seq2seq4repair_space>solicitud.solicitante<seq2seq4repair_space>in<seq2seq4repair_space>(select<seq2seq4repair_space>solicitante.id<seq2seq4repair_space>from<seq2seq4repair_space>Solicitante<seq2seq4repair_space>solicitante<seq2seq4repair_space>where<seq2seq4repair_space>solicitante.domicilio.provincia<seq2seq4repair_space>=<seq2seq4repair_space>'_35')" ) . fetch ( ) ; } else { allrows = SolicitudGenerica . find ( "select<seq2seq4repair_space>solicitud<seq2seq4repair_space>from<seq2seq4repair_space>SolicitudGenerica<seq2seq4repair_space>solicitud" ) . fetch ( ) ; } Map < String , Long > ids = ( ( Map < String , Long > ) ( TagMapStack . top ( "idParams" ) ) ) ; for ( SolicitudGenerica solicitud : allrows ) { Map < String , Object > vars = new HashMap < String , Object > ( ) ; vars . put ( "solicitud" , solicitud ) ; if ( secure . checkAcceso ( "solicitudes" , "leer" , ids , vars ) ) { rows . add ( solicitud ) ; } } <START_BUG> TableRenderResponse < SolicitudGenerica > response = new TableRenderResponse < SolicitudGenerica > ( rows , false , false , false , "editarSolicitud" , "" , "" , getAccion ( ) , ids ) ; <END_BUG> renderJSON ( response . toJSON ( "id" , "expedienteAed.idAed" , "estado" , "estadoValue" , "estadoUsuario" , "solicitante.numeroId" , "solicitante.nombreCompleto" ) ) ; } No newline ; at end ; of file ; }

Fix:
TableRenderResponse < SolicitudGenerica > response = new TableRenderResponse < SolicitudGenerica > ( rows , true , false , false , "editarSolicitud" , "" , "" , getAccion ( ) , ids ) ;
Buggy code:
@ ServerSetup ( LoggingProfilesTestCase . LoggingProfilesTestCaseSetup . class ) @ RunWith ( Arquillian . class ) public class LoggingProfilesTestCase extends AbstractLoggingTest { private static Logger log = Logger . getLogger ( LoggingProfilesTestCase . class ) ; @ ContainerResource private ManagementClient managementClient ; private static final String LOG_FILE_NAME = "profiles-test.log" ; private static final String PROFILE1_LOG_NAME = "dummy-profile1.log" ; private static final String PROFILE2_LOG_NAME = "dummy-profile2.log" ; private static final String CHANGED_LOG_NAME = "dummy-profile1-changed.log" ; private static File logFile ; private static File dummyLog1 ; private static File dummyLog2 ; private static File dummyLog1Changed ; static class LoggingProfilesTestCaseSetup extends AbstractMgmtServerSetupTask { @ Override protected void doSetup ( ManagementClient managementClient ) throws Exception { } @ Override public void tearDown ( ManagementClient managementClient , String containerId ) throws Exception { } } @ Deployment public static WebArchive createDeployment1 ( ) { } @ Deployment ( name = "Deployment2" ) public static WebArchive createDeployment2 ( ) { } @ RunAsClient @ Test @ InSequence ( 1 ) public void noWarningTest ( ) throws Exception { BufferedReader br = new BufferedReader ( new InputStreamReader ( new FileInputStream ( LoggingProfilesTestCase . logFile ) , StandardCharsets . UTF_8 ) ) ; String line ; while ( ( line = br . readLine ( ) ) != null ) { <START_BUG> if ( line . contains ( "JBAS011509" ) ) { <END_BUG> br . close ( ) ; Assert . fail ( ( "Every<seq2seq4repair_space>deployment<seq2seq4repair_space>should<seq2seq4repair_space>have<seq2seq4repair_space>defined<seq2seq4repair_space>its<seq2seq4repair_space>own<seq2seq4repair_space>logging<seq2seq4repair_space>profile.<seq2seq4repair_space>But<seq2seq4repair_space>found<seq2seq4repair_space>this<seq2seq4repair_space>line<seq2seq4repair_space>in<seq2seq4repair_space>logs:<seq2seq4repair_space>" + line ) ) ; } } br . close ( ) ; } @ RunAsClient @ Test @ InSequence ( 2 ) public void useDummyProfile1Test ( @ ArquillianResource ( LoggingServlet . class ) URL deployementUrl ) throws IOException , MalformedURLException { } @ RunAsClient @ Test @ InSequence ( 2 ) public void useDummyProfile2Test ( @ ContainerResource ManagementClient managementClient ) throws IOException , MalformedURLException { } private int testResponse ( URL url ) throws IOException , MalformedURLException { } @ RunAsClient @ Test @ InSequence ( 3 ) public void checkDummyLog1Test ( ) throws IOException { } @ RunAsClient @ Test @ InSequence ( 3 ) public void checkDummyLog2Test ( ) throws IOException { } @ RunAsClient @ Test @ InSequence ( 3 ) public void loggingTestLogTest ( ) throws IOException { } @ RunAsClient @ Test @ InSequence ( 4 ) public void runtimeChangesTest ( @ ArquillianResource ( LoggingServlet . class ) URL deployementUrl ) throws IOException { } static void applyUpdate ( ModelNode update , final ModelControllerClient client ) throws IOException { } }

Fix:
if ( line . contains ( "WFLYLOG0010" ) ) {
Buggy code:
public final class CommandManager implements ICommandManager { static boolean isCommandDefinitionChildOf ( String ancestor , String id , Map commandDefinitionsById ) { } private Set activeCommandIds = new HashSet ( ) ; private Map commandsById = new WeakHashMap ( ) ; private Set commandsWithListeners = new HashSet ( ) ; private Map commandDefinitionsById = new HashMap ( ) ; private List commandManagerListeners ; private ICommandRegistry commandRegistry ; private Set definedCommandIds = new HashSet ( ) ; private Set enabledCommandIds = new HashSet ( ) ; private Map keySequenceBindingsByCommandId = new HashMap ( ) ; public CommandManager ( ) { } public CommandManager ( ICommandRegistry commandRegistry ) { } public void addCommandManagerListener ( ICommandManagerListener commandManagerListener ) { } public Set getActiveCommandIds ( ) { } public ICommand getCommand ( String commandId ) { if ( commandId == null ) throw new NullPointerException ( ) ; Command command = ( ( Command ) ( commandsById . get ( commandId ) ) ) ; if ( command == null ) { <START_BUG> command = new Command ( this , commandId ) ; <END_BUG> updateCommand ( command ) ; commandsById . put ( commandId , command ) ; } return command ; } public Set getDefinedCommandIds ( ) { } public Set getEnabledCommandIds ( ) { } public void removeCommandManagerListener ( ICommandManagerListener commandManagerListener ) { } public void setActiveCommandIds ( Set activeCommandIds ) { } public void setEnabledCommandIds ( Set enabledCommandIds ) { } Set getCommandsWithListeners ( ) { } private void fireCommandManagerChanged ( ICommandManagerEvent commandManagerEvent ) { } private void notifyCommands ( Map commandEventsByCommandId ) { } private void readRegistry ( ) { } private ICommandEvent updateCommand ( Command command ) { } private Map updateCommands ( Collection commandIds ) { } }

Fix:
command = new Command ( commandsWithListeners , commandId ) ;