nus-yam/ex-repair huggingface dataset:
Buggy code:
public abstract class JobManager implements Runnable { protected IJob [ ] awaitingJobs = new IJob [ 10 ] ; protected int jobStart = 0 ; protected int jobEnd = - 1 ; protected boolean executing = false ; protected Thread thread ; private boolean enabled = true ; public static boolean VERBOSE = false ; public boolean activated = false ; public void activateProcessing ( ) { } public synchronized int awaitingJobsCount ( ) { } public synchronized IJob currentJob ( ) { } public synchronized void disable ( ) { } public void discardJobs ( String jobFamily ) { } public synchronized void enable ( ) { } public synchronized boolean isEnabled ( ) { } protected synchronized void moveToNextJob ( ) { } protected void notifyIdle ( long idlingTime ) { } public boolean performConcurrentJob ( IJob searchJob , int waitingPolicy , IProgressMonitor progress ) { } public abstract String processName ( ) { } public synchronized void request ( IJob job ) { } public void reset ( ) { } public void run ( ) { long idlingStart = - 1 ; activateProcessing ( ) ; while ( true ) { try { IJob job ; if ( ( job = currentJob ( ) ) == null ) { if ( idlingStart < 0 ) idlingStart = System . currentTimeMillis ( ) ; notifyIdle ( ( ( System . currentTimeMillis ( ) ) - idlingStart ) ) ; Thread . currentThread ( ) . sleep ( 500 ) ; continue ; } else { idlingStart = - 1 ; } if ( JobManager . VERBOSE ) { System . out . println ( ( ( ( "-><seq2seq4repair_space>executing<seq2seq4repair_space>(" + ( Thread . currentThread ( ) ) ) + "):<seq2seq4repair_space>" ) + job ) ) ; System . out . println ( ( ( "\t" + ( awaitingJobsCount ( ) ) ) + "<seq2seq4repair_space>awaiting<seq2seq4repair_space>jobs." ) ) ; } try { executing = true ; <START_BUG> boolean status = job . execute ( null ) ; <END_BUG> moveToNextJob ( ) ; } finally { executing = false ; Thread . currentThread ( ) . sleep ( 50 ) ; } } catch ( InterruptedException e ) { } } } public void shutdown ( ) { } }

Fix:
job . execute ( null ) ;
Buggy code:
public class CopyElementsOperation extends MultiOperation implements SuffixConstants { private Map sources = new HashMap ( ) ; public CopyElementsOperation ( IJavaElement [ ] elementsToCopy , IJavaElement [ ] destContainers , boolean force ) { } public CopyElementsOperation ( IJavaElement [ ] elementsToCopy , IJavaElement destContainer , boolean force ) { } protected String getMainTaskName ( ) { } protected JavaModelOperation getNestedOperation ( IJavaElement element ) { } private String getSourceFor ( IJavaElement element ) throws JavaModelException { } protected boolean isRenamingMainType ( IJavaElement element , IJavaElement dest ) throws JavaModelException { if ( ( ( isRename ( ) ) || ( ( getNewNameFor ( element ) ) != null ) ) && ( ( dest . getElementType ( ) ) == ( IJavaElement . COMPILATION_UNIT ) ) ) { String typeName = dest . getElementName ( ) ; <START_BUG> typeName = typeName . substring ( 0 , ( ( typeName . length ( ) ) - 5 ) ) ; <END_BUG> return ( element . getElementName ( ) . equals ( typeName ) ) && ( element . getParent ( ) . equals ( dest ) ) ; } return false ; } protected void processElement ( IJavaElement element ) throws JavaModelException { } private IJavaElement resolveRenameAnchor ( IJavaElement element ) throws JavaModelException { } protected IJavaModelStatus verify ( ) { } protected void verify ( IJavaElement element ) throws JavaModelException { } }

Fix:
typeName = Util . getNameWithoutJavaLikeExtension ( typeName ) ;
Buggy code:
public class StreamOut { private static Logger logger = Logger . getLogger ( StreamOut . class ) ; static String TABLE_NAME = "STREAMING-TABLE-NAME" ; public static void transferRanges ( InetAddress target , String tableName , Collection < Range > ranges , Runnable callback ) { } public static void transferSSTables ( InetAddress target , List < SSTableReader > sstables , String table ) throws IOException { PendingFile [ ] pendingFiles = new PendingFile [ ( SSTable . FILES_ON_DISK ) * ( sstables . size ( ) ) ] ; int i = 0 ; for ( SSTableReader sstable : sstables ) { for ( String filename : sstable . getAllFilenames ( ) ) { File file = new File ( filename ) ; pendingFiles [ ( i ++ ) ] = new PendingFile ( file . getAbsolutePath ( ) , file . length ( ) , table ) ; } } if ( StreamOut . logger . isDebugEnabled ( ) ) StreamOut . logger . debug ( ( "Stream<seq2seq4repair_space>context<seq2seq4repair_space>metadata<seq2seq4repair_space>" + ( StringUtils . join ( pendingFiles , ( ( ( ",<seq2seq4repair_space>" + "<seq2seq4repair_space>" ) + ( sstables . size ( ) ) ) + "<seq2seq4repair_space>sstables." ) ) ) ) ) ; StreamOutManager . get ( target ) . addFilesToStream ( pendingFiles ) ; StreamInitiateMessage biMessage = new StreamInitiateMessage ( pendingFiles ) ; Message message = StreamInitiateMessage . makeStreamInitiateMessage ( biMessage ) ; <START_BUG> message . addHeader ( StreamOut . TABLE_NAME , table . getBytes ( ) ) ; <END_BUG> if ( StreamOut . logger . isDebugEnabled ( ) ) StreamOut . logger . debug ( ( ( "Sending<seq2seq4repair_space>a<seq2seq4repair_space>stream<seq2seq4repair_space>initiate<seq2seq4repair_space>message<seq2seq4repair_space>to<seq2seq4repair_space>" + target ) + "<seq2seq4repair_space>..." ) ) ; instance . sendOneWay ( message , target ) ; if ( ( pendingFiles . length ) > 0 ) { StreamOut . logger . info ( ( ( "Waiting<seq2seq4repair_space>for<seq2seq4repair_space>transfer<seq2seq4repair_space>to<seq2seq4repair_space>" + target ) + "<seq2seq4repair_space>to<seq2seq4repair_space>complete" ) ) ; StreamOutManager . get ( target ) . waitForStreamCompletion ( ) ; StreamOut . logger . info ( ( "Done<seq2seq4repair_space>with<seq2seq4repair_space>transfer<seq2seq4repair_space>to<seq2seq4repair_space>" + target ) ) ; } } }

Fix:
message . setHeader ( StreamOut . TABLE_NAME , table . getBytes ( ) ) ;
Buggy code:
public class ZKPropertiesWriter extends SimplePropertiesWriter { private static final Logger log = LoggerFactory . getLogger ( ZKPropertiesWriter . class ) ; private String path ; private SolrZkClient zkClient ; @ Override public void init ( DataImporter dataImporter , Map < String , String > params ) { } @ Override protected void findDirectory ( DataImporter dataImporter , Map < String , String > params ) { } @ Override public boolean isWritable ( ) { } @ Override public void persist ( Map < String , Object > propObjs ) { } @ Override public Map < String , Object > readIndexerProperties ( ) { Properties props = new Properties ( ) ; try { byte [ ] data = zkClient . getData ( path , null , null , false ) ; if ( data != null ) { props . load ( new StringReader ( new String ( data , "UTF-8" ) ) ) ; } <START_BUG> } catch ( Throwable e ) { <END_BUG> ZKPropertiesWriter . log . warn ( ( ( ( "Could<seq2seq4repair_space>not<seq2seq4repair_space>read<seq2seq4repair_space>DIH<seq2seq4repair_space>properties<seq2seq4repair_space>from<seq2seq4repair_space>" + ( path ) ) + "<seq2seq4repair_space>:" ) + ( e . getClass ( ) ) ) , e ) ; } return propertiesToMap ( props ) ; } }

Fix:
} catch ( Exception e ) {
Buggy code:
public abstract class MarkupContainer extends Component { private static final Log log = LogFactory . getLog ( MarkupContainer . class ) ; private static final Map markupCache = new HashMap ( ) ; private static final int MINIMAP_MAX_ENTRIES = 8 ; private static final boolean optimizeChildMapsForSpace = false ; private Map childForName = Collections . EMPTY_MAP ; private transient MarkupStream markupStream ; public MarkupContainer ( final String name ) { } public MarkupContainer ( String name , IModel model ) { } public MarkupContainer ( String name , Serializable object ) { } public MarkupContainer ( String name , Serializable object , String expression ) { } public MarkupContainer add ( final Component child ) { } public final Component get ( final String path ) { } public final Iterator iterator ( ) { } public final boolean contains ( final Component component , final boolean recurse ) { if ( recurse ) { for ( Component current = component ; current != null ; ) { <START_BUG> MarkupContainer parent = component . getParent ( ) ; <END_BUG> if ( parent == ( this ) ) { return true ; } current = parent ; } return false ; } else { return ( component . getParent ( ) ) == ( this ) ; } } public void removeAll ( ) { } public MarkupContainer replace ( final Component child ) { } public final int size ( ) { } public String toString ( ) { } public final Object visitChildren ( final Class c , final IVisitor visitor ) { } public final Object visitChildren ( final IVisitor visitor ) { } protected final MarkupStream findMarkupStream ( ) { } protected final MarkupStream getMarkupStream ( ) { } protected String getMarkupType ( ) { } protected void onComponentTagBody ( final MarkupStream markupStream , final ComponentTag openTag ) { } protected void onRender ( ) { } protected void onReset ( ) { } protected final void renderAssociatedMarkup ( final String openTagName , final String exceptionMessage ) { } protected final void renderComponentTagBody ( final MarkupStream markupStream , final ComponentTag openTag ) { } protected boolean resolveComponent ( final MarkupStream markupStream , final ComponentTag tag ) { } protected final void setMarkupStream ( final MarkupStream markupStream ) { } final Markup getAssociatedMarkup ( ) { } final MarkupStream getAssociatedMarkupStream ( ) { } final boolean hasAssociatedMarkup ( ) { } final void renderAll ( final MarkupStream markupStream ) { } private Markup loadMarkup ( final Application application , final String key , final IResource markupResource ) throws IOException , ParseException , ResourceNotFoundException { } private Markup loadMarkupAndWatchForChanges ( final String key , final IResource markupResource ) { } private String markupKey ( ) { } private void optimize ( ) { } private void renderNext ( final MarkupStream markupStream ) { } }

Fix:
final MarkupContainer parent = current . getParent ( ) ;
Buggy code:
public class PopupList { Shell shell ; List list ; int minimumWidth ; public PopupList ( Shell parent ) { } public PopupList ( Shell parent , int style ) { } private static int checkStyle ( int style ) { } public Font getFont ( ) { } public String [ ] getItems ( ) { } public int getMinimumWidth ( ) { } public String open ( Rectangle rect ) { <START_BUG> Point listSize = list . computeSize ( rect . width , DEFAULT ) ; <END_BUG> Rectangle screenSize = shell . getDisplay ( ) . getBounds ( ) ; int spaceBelow = ( ( screenSize . height ) - ( ( rect . y ) + ( rect . height ) ) ) - 30 ; int spaceAbove = ( rect . y ) - 30 ; int y = 0 ; if ( ( spaceAbove > spaceBelow ) && ( ( listSize . y ) > spaceBelow ) ) { if ( ( listSize . y ) > spaceAbove ) { listSize . y = spaceAbove ; } else { listSize . y += 2 ; } y = ( rect . y ) - ( listSize . y ) ; } else { if ( ( listSize . y ) > spaceBelow ) { listSize . y = spaceBelow ; } else { listSize . y += 2 ; } y = ( rect . y ) + ( rect . height ) ; } listSize . x = rect . width ; if ( ( listSize . x ) < ( minimumWidth ) ) listSize . x = minimumWidth ; int x = ( ( rect . x ) + ( rect . width ) ) - ( listSize . x ) ; shell . setBounds ( x , y , listSize . x , listSize . y ) ; shell . open ( ) ; list . setFocus ( ) ; Display display = shell . getDisplay ( ) ; while ( ( ! ( shell . isDisposed ( ) ) ) && ( shell . isVisible ( ) ) ) { if ( ! ( display . readAndDispatch ( ) ) ) display . sleep ( ) ; } String result = null ; if ( ! ( shell . isDisposed ( ) ) ) { String [ ] strings = list . getSelection ( ) ; shell . dispose ( ) ; if ( ( strings . length ) != 0 ) result = strings [ 0 ] ; } return result ; } public void select ( String string ) { } public void setFont ( Font font ) { } public void setItems ( String [ ] strings ) { } public void setMinimumWidth ( int width ) { } }

Fix:
Point listSize = list . computeSize ( rect . width , DEFAULT , false ) ;
Buggy code:
public class XSLTProcess extends MatchingTask { private File destDir = null ; private File baseDir = null ; private String xslFile = null ; private String targetExtension = ".html" ; private Vector params = new Vector ( ) ; private File inFile = null ; private File outFile = null ; private String processor ; private Path classpath = null ; private XSLTLiaison liaison ; private boolean stylesheetLoaded = false ; private boolean force = false ; private FileUtils fileUtils ; public XSLTProcess ( ) { } public void execute ( ) throws BuildException { } public void setForce ( boolean force ) { } public void setBasedir ( File dir ) { } public void setDestdir ( File dir ) { } public void setExtension ( String name ) { } public void setStyle ( String xslFile ) { } public void setClasspath ( Path classpath ) { } public Path createClasspath ( ) { } public void setClasspathRef ( Reference r ) { } public void setProcessor ( String processor ) { } private void resolveProcessor ( String proc ) throws Exception { } private Class loadClass ( String classname ) throws Exception { } public void setOut ( File outFile ) { } public void setIn ( File inFile ) { } private void process ( File baseDir , String xmlFile , File destDir , File stylesheet ) throws BuildException { String fileExt = targetExtension ; File outFile = null ; File inFile = null ; try { long styleSheetLastModified = stylesheet . lastModified ( ) ; inFile = new File ( baseDir , xmlFile ) ; int dotPos = xmlFile . lastIndexOf ( '.' ) ; if ( dotPos > 0 ) { outFile = new File ( destDir , ( ( xmlFile . substring ( 0 , xmlFile . lastIndexOf ( '.' ) ) ) + fileExt ) ) ; } else { outFile = new File ( destDir , ( xmlFile + fileExt ) ) ; } if ( ( ( force ) || ( ( inFile . lastModified ( ) ) > ( outFile . lastModified ( ) ) ) ) || ( styleSheetLastModified > ( outFile . lastModified ( ) ) ) ) { ensureDirectoryFor ( outFile ) ; <START_BUG> log ( ( "Transforming<seq2seq4repair_space>into<seq2seq4repair_space>" + destDir ) ) ; <END_BUG> configureLiaison ( stylesheet ) ; liaison . transform ( inFile , outFile ) ; } } catch ( Exception ex ) { log ( ( "Failed<seq2seq4repair_space>to<seq2seq4repair_space>process<seq2seq4repair_space>" + inFile ) , MSG_INFO ) ; if ( outFile != null ) { outFile . delete ( ) ; } throw new BuildException ( ex ) ; } } private void process ( File inFile , File outFile , File stylesheet ) throws BuildException { } private void ensureDirectoryFor ( File targetFile ) throws BuildException { } protected XSLTLiaison getLiaison ( ) { } public XSLTProcess . Param createParam ( ) { } public class Param { private String name = null ; private String expression = null ; public void setName ( String name ) { } public void setExpression ( String expression ) { } public String getName ( ) throws BuildException { } public String getExpression ( ) throws BuildException { } } protected void configureLiaison ( File stylesheet ) throws BuildException { } }

Fix:
log ( ( ( ( "Processing<seq2seq4repair_space>" + inFile ) + "<seq2seq4repair_space>to<seq2seq4repair_space>" ) + outFile ) ) ;
Buggy code:
public class NewsFragment extends Fragment { private LinearLayout container ; private TextView info ; private News news ; private ProgressDialog progressDialog ; private View rootView ; NewsFragment . NetTask task ; private TextView title ; public View onCreateView ( LayoutInflater inflater , ViewGroup container , Bundle savedInstanceState ) { } public void onActivityCreated ( Bundle savedInstanceState ) { } private void findView ( ) { } private DownloadService downloadService ; private void bindService ( ) { } private ServiceConnection conn = new ServiceConnection ( ) { public void onServiceConnected ( ComponentName className , IBinder binder ) { } public void onServiceDisconnected ( ComponentName arg0 ) { } } ; private void getNews ( ) { } class BackListener implements OnCancelListener { @ Override public void onCancel ( DialogInterface arg0 ) { } } class NetTask extends AsyncTask < Void , Integer , Boolean > { private String url ; protected void onPreExecute ( ) { } protected Boolean doInBackground ( Void ... arg0 ) { } protected void onPostExecute ( Boolean result ) { } } private void setNews ( ) { title . setText ( news . getTitle ( ) ) ; info . setText ( news . getInfo ( ) ) ; Document doc = Jsoup . parse ( news . getContent ( ) ) ; Elements els = doc . select ( "body>div,<seq2seq4repair_space>body>p,<seq2seq4repair_space>body>table" ) ; for ( Element e : els ) { if ( e . toString ( ) . contains ( "<tbody>" ) ) { for ( Element table : e . select ( "table" ) ) { <START_BUG> container . addView ( new com . doge . dyjw . view . TableView ( getActivity ( ) , table ) ) ; <END_BUG> } } else if ( ! ( e . toString ( ) . contains ( "<img" ) ) ) { UrlTextView t = new UrlTextView ( getActivity ( ) ) ; t . setLayoutParams ( new ViewGroup . LayoutParams ( LayoutParams . MATCH_PARENT , LayoutParams . WRAP_CONTENT ) ) ; t . setTextSize ( COMPLEX_UNIT_SP , 17 ) ; t . setText ( Html . fromHtml ( e . toString ( ) ) , download ) ; t . setTextColor ( getResources ( ) . getColor ( text_black ) ) ; t . setMovementMethod ( LinkMovementMethod . getInstance ( ) ) ; container . addView ( t ) ; } else { NetImageView img = new NetImageView ( getActivity ( ) , e . select ( "img" ) . get ( 0 ) . attr ( "src" ) ) ; container . addView ( img ) ; } } } OnDownloadListener download = new UrlTextView . OnDownloadListener ( ) { @ Override public boolean download ( String url , String filename ) { } } ; public void onDestroy ( ) { } }

Fix:
container . addView ( new com . doge . dyjw . view . TableView ( getActivity ( ) , table , download ) ) ;
Buggy code:
public class FeatureVariances { private DataSet dset ; public float [ ] intVariances ; public float [ ] floatVariances ; public FeatureVariances ( DataSet dataset ) { } public FeatureVariances ( Cluster clust ) { } public void calculateAllVariances ( Cluster clust ) throws Exception { } public void calculateAllVariances ( ) throws Exception { } public float varianceNorm ( ) { float sum = 0.0F ; for ( int dint = 0 ; dint < ( dset . getNumIntAttr ( ) ) ; dint ++ ) { if ( DataMineConstants . isAcceptableFloat ( intVariances [ dint ] ) ) { sum += Math . pow ( Math . abs ( intVariances [ dint ] ) , 2 ) ; } } <START_BUG> for ( int dfloat = 0 ; dfloat < ( dset . getNumIntAttr ( ) ) ; dfloat ++ ) { <END_BUG> if ( DataMineConstants . isAcceptableFloat ( floatVariances [ dfloat ] ) ) { sum += Math . pow ( Math . abs ( floatVariances [ dfloat ] ) , 2 ) ; } } return ( ( float ) ( Math . pow ( sum , 0.5 ) ) ) ; } No newline ; at end ; of file ; }

Fix:
for ( int dfloat = 0 ; dfloat < ( dset . getNumFloatAttr ( ) ) ; dfloat ++ ) {
Buggy code:
public final class InsertNode extends DMLModStatementNode { public ResultColumnList targetColumnList ; public boolean deferred ; public ValueNode checkConstraints ; public Properties targetProperties ; public FKInfo fkInfo ; protected boolean bulkInsert ; private boolean bulkInsertReplace ; protected RowLocation [ ] autoincRowLocation ; public void init ( Object targetName , Object insertColumns , Object queryExpression , Object targetProperties ) { } public String toString ( ) { } public String statementToString ( ) { } public void printSubNodes ( int depth ) { } public void bindStatement ( ) throws StandardException { } private void enhanceAndCheckForAutoincrement ( ResultSetNode resultSet , boolean inOrder , int numTableColumns , int [ ] colMap , DataDictionary dataDictionary , TableDescriptor targetTableDescriptor , FromVTI targetVTI ) throws StandardException { if ( resultSet instanceof SingleChildResultSetNode ) { enhanceAndCheckForAutoincrement ( ( ( SingleChildResultSetNode ) ( resultSet ) ) . getChildResult ( ) , inOrder , numTableColumns , colMap , dataDictionary , targetTableDescriptor , targetVTI ) ; if ( ( ! inOrder ) || ( ( resultSet . resultColumns . size ( ) ) < numTableColumns ) ) resultSet . enhanceRCLForInsert ( numTableColumns , colMap , dataDictionary , targetTableDescriptor , targetVTI ) ; } else if ( resultSet instanceof UnionNode ) { enhanceAndCheckForAutoincrement ( ( ( TableOperatorNode ) ( resultSet ) ) . getLeftResultSet ( ) , inOrder , numTableColumns , colMap , dataDictionary , targetTableDescriptor , targetVTI ) ; enhanceAndCheckForAutoincrement ( ( ( TableOperatorNode ) ( resultSet ) ) . getRightResultSet ( ) , inOrder , numTableColumns , colMap , dataDictionary , targetTableDescriptor , targetVTI ) ; if ( ( ! inOrder ) || ( ( resultSet . resultColumns . size ( ) ) < numTableColumns ) ) resultSet . enhanceRCLForInsert ( numTableColumns , colMap , dataDictionary , targetTableDescriptor , targetVTI ) ; } else { if ( ( ! inOrder ) || ( ( resultSet . resultColumns . size ( ) ) < numTableColumns ) ) resultSet . enhanceRCLForInsert ( numTableColumns , colMap , dataDictionary , targetTableDescriptor , targetVTI ) ; <START_BUG> resultColumnList . checkAutoincrement ( resultSet . getResultColumns ( ) ) ; <END_BUG> } } int getPrivType ( ) { } public boolean referencesSessionSchema ( ) throws StandardException { } private void verifyTargetProperties ( DataDictionary dd ) throws StandardException { } private boolean verifyBulkInsert ( DataDictionary dd , String mode ) throws StandardException { } public ConstantAction makeConstantAction ( ) throws StandardException { } public boolean [ ] getIndexedCols ( ) throws StandardException { } public void generate ( ActivationClassBuilder acb , MethodBuilder mb ) throws StandardException { } protected final int getStatementType ( ) { } static final int getStatementType ( Properties targetProperties ) { } private void getAffectedIndexes ( TableDescriptor td ) throws StandardException { } }

Fix:
resultColumnList . forbidOverrides ( resultSet . getResultColumns ( ) ) ;
Buggy code:
public class DsDeploymentActivator { public Collection < ServiceController < ? > > activateServices ( final ServiceTarget serviceTarget , final ServiceListener < Object > ... listeners ) { } public void activateProcessors ( final DeploymentProcessorTarget updateContext ) { updateContext . addDeploymentProcessor ( SUBSYSTEM_NAME , PARSE , PARSE_DSXML_DEPLOYMENT , new DsXmlDeploymentParsingProcessor ( ) ) ; updateContext . addDeploymentProcessor ( SUBSYSTEM_NAME , PARSE , PARSE_DATA_SOURCE_DEFINITION_ANNOTATION , new DataSourceDefinitionAnnotationParser ( ) ) ; updateContext . addDeploymentProcessor ( SUBSYSTEM_NAME , POST_MODULE , POST_MODULE_DATASOURCE_REF , new DataSourceDefinitionDeploymentDescriptorParser ( ) ) ; <START_BUG> updateContext . addDeploymentProcessor ( SUBSYSTEM_NAME , INSTALL , INSTALL_DSXML_DEPLOYMENT , new DsXmlDeploymentInstallProcessor ( ) ) ; <END_BUG> } }

Fix:
updateContext . addDeploymentProcessor ( SUBSYSTEM_NAME , FIRST_MODULE_USE , FIRST_MODULE_USE_DSXML_DEPLOYMENT , new DsXmlDeploymentInstallProcessor ( ) ) ;
Buggy code:
public class ZeroPaddingIntegerConverter extends AbstractIntegerConverter < Integer > { private static final long serialVersionUID = 1L ; private final int zeroPadLength ; public ZeroPaddingIntegerConverter ( int zeroPadLength ) { } @ Override public String convertToString ( Integer value , Locale locale ) { } public Integer convertToObject ( final String value , Locale locale ) { final Number number = parse ( value , Integer . MIN_VALUE , Integer . MAX_VALUE , locale ) ; if ( number == null ) { return null ; } <START_BUG> return new Integer ( number . intValue ( ) ) ; <END_BUG> } @ Override protected Class < Integer > getTargetType ( ) { } }

Fix:
return number . intValue ( ) ;
Buggy code:
public abstract class Query implements Serializable , Cloneable { private float boost = 1.0F ; public void setBoost ( float b ) { } public float getBoost ( ) { } public abstract String toString ( String field ) { } public String toString ( ) { } protected Weight createWeight ( Searcher searcher ) { } public Weight weight ( Searcher searcher ) throws IOException { } public Query rewrite ( IndexReader reader ) throws IOException { } public Query combine ( Query [ ] queries ) { } public static Query mergeBooleanQueries ( Query [ ] queries ) { } public Object clone ( ) { try { return ( ( Query ) ( super . clone ( ) ) ) ; } catch ( CloneNotSupportedException e ) { <START_BUG> throw new RuntimeException ( e ) ; <END_BUG> } } }

Fix:
throw new RuntimeException ( ( "Clone<seq2seq4repair_space>not<seq2seq4repair_space>supported:<seq2seq4repair_space>" + ( e . getMessage ( ) ) ) ) ;
Buggy code:
public class BitInputStream implements Closeable { private static final int MAXIMUM_CACHE_SIZE = 31 ; private static final int [ ] MASKS = new int [ ( BitInputStream . MAXIMUM_CACHE_SIZE ) + 1 ] ; private final InputStream in ; private final ByteOrder byteOrder ; private int bitsCached = 0 ; private int bitsCachedSize = 0 ; public BitInputStream ( final InputStream in , final ByteOrder byteOrder ) { } public void close ( ) throws IOException { } public void clearBitCache ( ) { } public int readBits ( final int count ) throws IOException { if ( ( count < 0 ) || ( count > ( BitInputStream . MAXIMUM_CACHE_SIZE ) ) ) { <START_BUG> throw new IllegalArgumentException ( ( "count<seq2seq4repair_space>must<seq2seq4repair_space>not<seq2seq4repair_space>be<seq2seq4repair_space>negative<seq2seq4repair_space>or<seq2seq4repair_space>bigger<seq2seq4repair_space>than<seq2seq4repair_space>" + ( BitInputStream . MAXIMUM_CACHE_SIZE ) ) ) ; <END_BUG> } while ( ( bitsCachedSize ) < count ) { final int nextByte = in . read ( ) ; if ( nextByte < 0 ) { return nextByte ; } if ( ( byteOrder ) == ( ByteOrder . LITTLE_ENDIAN ) ) { bitsCached |= nextByte << ( bitsCachedSize ) ; } else { bitsCached <<= 8 ; bitsCached |= nextByte ; } bitsCachedSize += 8 ; } final int bitsOut ; if ( ( byteOrder ) == ( ByteOrder . LITTLE_ENDIAN ) ) { bitsOut = ( bitsCached ) & ( BitInputStream . MASKS [ count ] ) ; bitsCached >>>= count ; } else { bitsOut = ( ( bitsCached ) > > ( ( bitsCachedSize ) - count ) ) & ( BitInputStream . MASKS [ count ] ) ; } bitsCachedSize -= count ; return bitsOut ; } }

Fix:
throw new IllegalArgumentException ( ( "count<seq2seq4repair_space>must<seq2seq4repair_space>not<seq2seq4repair_space>be<seq2seq4repair_space>negative<seq2seq4repair_space>or<seq2seq4repair_space>greater<seq2seq4repair_space>than<seq2seq4repair_space>" + ( BitInputStream . MAXIMUM_CACHE_SIZE ) ) ) ;
Buggy code:
public class MorningCardActivity extends ActionBarActivity { private HomeFragment mHomeFragment ; private String mTrackDate ; @ Override protected void onCreate ( Bundle savedInstanceState ) { } @ Override public void onResume ( ) { super . onResume ( ) ; <START_BUG> SharedPreferences preferences = getSharedPreferences ( TMP_PREF_FILE , MODE_PRIVATE ) ; <END_BUG> SharedPreferences . Editor editor = preferences . edit ( ) ; editor . putString ( "morningTrackDate" , mTrackDate ) ; editor . commit ( ) ; } @ Override public boolean onCreateOptionsMenu ( Menu menu ) { } @ Override public boolean onOptionsItemSelected ( MenuItem item ) { } }

Fix:
SharedPreferences preferences = getSharedPreferences ( TMP_PREF_FILE , MODE_MULTI_PROCESS ) ;
Buggy code:
public class WindowsIT { @ BeforeClass @ AfterClass public static void clean ( ) { } @ Before public void checkPlatform ( ) { } @ Test public void completeTest ( ) throws IOException , InterruptedException , KeyManagementException , KeyStoreException , NoSuchAlgorithmException , CertificateException { } private void installTrustedCaCert ( ) throws IOException , InterruptedException { } private void generateCsr ( ) throws IOException , InterruptedException { } private void acceptCert ( ) throws IOException , InterruptedException { <START_BUG> final Process process = new ProcessBuilder ( "certreq" , "-accept<seq2seq4repair_space>cert.cer" ) . redirectError ( ProcessBuilder . Redirect . INHERIT ) . redirectOutput ( ProcessBuilder . Redirect . INHERIT ) . start ( ) ; <END_BUG> process . waitFor ( ) ; } private void configureSsl ( final String certHash , final String appId ) throws IOException , InterruptedException { } private static String getThumbPrint ( final X509Certificate cert ) throws NoSuchAlgorithmException , CertificateEncodingException { } private static String hexify ( final byte [ ] bytes ) { } }

Fix:
final Process process = new ProcessBuilder ( "certreq" , "-accept" , "cert.cer" ) . redirectError ( ProcessBuilder . Redirect . INHERIT ) . redirectOutput ( ProcessBuilder . Redirect . INHERIT ) . start ( ) ;
Buggy code:
public class MMetrics extends AbstractMetamataTask { protected String granularity = null ; protected File outFile = null ; protected File tmpFile = createTmpFile ( ) ; protected Path path = null ; public MMetrics ( ) { } public void setGranularity ( String granularity ) { } public void setTofile ( File file ) { } public Path createPath ( ) { if ( ( path ) == null ) { <START_BUG> path = new Path ( project ) ; <END_BUG> } return path ; } protected Vector getOptions ( ) { } protected void checkOptions ( ) throws TaskException { } protected void cleanUp ( ) throws TaskException { } protected ExecuteStreamHandler createStreamHandler ( ) { } protected void execute0 ( ExecuteStreamHandler handler ) throws TaskException { } protected void transformFile ( ) throws TaskException { } }

Fix:
path = new Path ( getProject ( ) ) ;
Buggy code:
public class WebAsyncManagerTests { private WebAsyncManager asyncManager ; private AsyncWebRequest asyncWebRequest ; @ Before public void setUp ( ) { } @ Test public void startAsyncProcessingWithoutAsyncWebRequest ( ) { } @ Test public void isConcurrentHandlingStarted ( ) { } @ Test ( expected = IllegalArgumentException . class ) public void setAsyncWebRequestAfterAsyncStarted ( ) { } @ Test public void startCallableProcessing ( ) throws Exception { } @ Test public void startCallableProcessingCallableException ( ) throws Exception { } @ Test public void startCallableProcessingPreProcessException ( ) throws Exception { } @ Test public void startCallableProcessingPostProcessException ( ) throws Exception { } @ Test public void startCallableProcessingPostProcessContinueAfterException ( ) throws Exception { } @ Test public void startCallableProcessingWithAsyncTask ( ) { AsyncTaskExecutor executor = createMock ( AsyncTaskExecutor . class ) ; expect ( executor . submit ( ( ( Runnable ) ( notNull ( ) ) ) ) ) . andReturn ( null ) ; replay ( executor ) ; this . asyncWebRequest . setTimeout ( 1000L ) ; this . asyncWebRequest . addTimeoutHandler ( EasyMock . < Runnable > anyObject ( ) ) ; this . asyncWebRequest . addCompletionHandler ( EasyMock . < Runnable > anyObject ( ) ) ; this . asyncWebRequest . startAsync ( ) ; replay ( this . asyncWebRequest ) ; @ SuppressWarnings ( "unchecked" ) <START_BUG> MvcAsyncTask < Object > asyncTask = new MvcAsyncTask < Object > ( 1000L , executor , createMock ( Callable . class ) ) ; <END_BUG> this . asyncManager . startCallableProcessing ( asyncTask ) ; verify ( executor , this . asyncWebRequest ) ; } @ Test public void startCallableProcessingNullInput ( ) { } @ Test public void startDeferredResultProcessing ( ) throws Exception { } @ Test public void startDeferredResultProcessingPreProcessException ( ) throws Exception { } @ Test public void startDeferredResultProcessingPostProcessException ( ) throws Exception { } @ Test public void startDeferredResultProcessingNullInput ( ) { } private void setupDefaultAsyncScenario ( ) { } private final class StubCallable implements Callable < Object > { private Object value ; public StubCallable ( Object value ) { } public Object call ( ) throws Exception { } } @ SuppressWarnings ( "serial" ) private static class SyncTaskExecutor extends SimpleAsyncTaskExecutor { @ Override public void execute ( Runnable task , long startTimeout ) { } } }

Fix:
WebAsyncTask < Object > asyncTask = new WebAsyncTask < Object > ( 1000L , executor , createMock ( Callable . class ) ) ;
Buggy code:
public class ArArchiveInputStream extends ArchiveInputStream { private final InputStream input ; private long offset = 0 ; private boolean closed ; private ArArchiveEntry currentEntry = null ; private byte [ ] namebuffer = null ; private long entryOffset = - 1 ; private final byte [ ] NAME_BUF = new byte [ 16 ] ; private final byte [ ] LAST_MODIFIED_BUF = new byte [ 12 ] ; private final byte [ ] ID_BUF = new byte [ 6 ] ; private final byte [ ] FILE_MODE_BUF = new byte [ 8 ] ; private final byte [ ] LENGTH_BUF = new byte [ 10 ] ; public ArArchiveInputStream ( final InputStream pInput ) { } public ArArchiveEntry getNextArEntry ( ) throws IOException { } private String getExtendedName ( int offset ) throws IOException { } private long asLong ( byte [ ] input ) { } private int asInt ( byte [ ] input ) { } private int asInt ( byte [ ] input , boolean treatBlankAsZero ) { } private int asInt ( byte [ ] input , int base ) { } private int asInt ( byte [ ] input , int base , boolean treatBlankAsZero ) { } @ Override public ArchiveEntry getNextEntry ( ) throws IOException { } @ Override public void close ( ) throws IOException { } @ Override public int read ( byte [ ] b , final int off , final int len ) throws IOException { } public static boolean matches ( byte [ ] signature , int length ) { } static final String BSD_LONGNAME_PREFIX = "#1//" ; private static final int BSD_LONGNAME_PREFIX_LEN = ArArchiveInputStream . BSD_LONGNAME_PREFIX . length ( ) ; private static final String BSD_LONGNAME_PATTERN = ( "^" + ( ArArchiveInputStream . BSD_LONGNAME_PREFIX ) ) + "\\d+" ; private static boolean isBSDLongName ( String name ) { } private String getBSDLongName ( String bsdLongName ) throws IOException { } private static final String GNU_STRING_TABLE_NAME = "////" ; private static boolean isGNUStringTable ( String name ) { } private ArArchiveEntry readGNUStringTable ( byte [ ] length ) throws IOException { int bufflen = asInt ( length ) ; namebuffer = new byte [ bufflen ] ; <START_BUG> int read = read ( namebuffer , 0 , bufflen ) ; <END_BUG> if ( read != bufflen ) { throw new IOException ( ( ( ( "Failed<seq2seq4repair_space>to<seq2seq4repair_space>read<seq2seq4repair_space>complete<seq2seq4repair_space>////<seq2seq4repair_space>record:<seq2seq4repair_space>expected=" + bufflen ) + "<seq2seq4repair_space>read=" ) + read ) ) ; } return new ArArchiveEntry ( ArArchiveInputStream . GNU_STRING_TABLE_NAME , bufflen ) ; } private static final String GNU_LONGNAME_PATTERN = "^//\\d+" ; private boolean isGNULongName ( String name ) { } }

Fix:
int read = IOUtils . readFully ( this , namebuffer , 0 , bufflen ) ;
Buggy code:
public class CyActivator extends AbstractCyActivator { private ProjectManager projectMgr ; private TripleStoreManager conMgr ; private PreferenceManager prefs ; private BundleContext context ; private CySwingApplication cySwingApplication ; private JMenu recentMenu = null ; private final AbstractAction DUMMY = new AbstractAction ( "dummy" ) { @ Override public void actionPerformed ( ActionEvent e ) { } } ; private void updateRecentMenu ( ) { } private JMenu searchMenu = null ; void updateSearchMenu ( ) { } @ Override public void start ( BundleContext context ) throws Exception { try { this . context = context ; File propsFile = new File ( FileUtils . getApplicationDir ( ) , "CytoscapeConfiguration//GeneralSparql.properties" ) ; propsFile . getParentFile ( ) . mkdirs ( ) ; Properties defaultValues = new Properties ( ) ; <START_BUG> defaultValues . put ( MARRS_DRIVER , "Empty<seq2seq4repair_space>Jena<seq2seq4repair_space>Model" ) ; <END_BUG> prefs = new PreferenceManager ( propsFile , defaultValues ) ; prefs . load ( ) ; cySwingApplication = getService ( context , CySwingApplication . class ) ; JFrame frame = cySwingApplication . getJFrame ( ) ; conMgr = new TripleStoreManager ( frame , prefs ) ; CySwingAppAdapter adapter = getService ( context , CySwingAppAdapter . class ) ; CyNetworkNaming cyNetworkNaming = getService ( context , CyNetworkNaming . class ) ; final CytoscapeV3Mapper mapper = new CytoscapeV3Mapper ( this , adapter , conMgr , cyNetworkNaming , frame ) ; projectMgr = new ProjectManager ( frame , prefs , conMgr , mapper ) ; loadPreviousProject ( ) ; registerMenu ( context , "Apps.General<seq2seq4repair_space>SPARQL" , conMgr . configureAction ) ; registerMenu ( context , "Apps.General<seq2seq4repair_space>SPARQL" , projectMgr . editAction ) ; registerMenu ( context , "Apps.General<seq2seq4repair_space>SPARQL" , projectMgr . loadAction ) ; updateRecentMenu ( ) ; registerNodeContextMenu ( context , new MarrsNodeViewContextMenuFactory ( projectMgr , mapper , frame ) ) ; } catch ( Throwable t ) { t . printStackTrace ( ) ; throw new IllegalStateException ( t ) ; } } static class MySubMenuItemAction extends AbstractCyAction { public MySubMenuItemAction ( CySwingApplication desktopApp ) { } @ Override public void actionPerformed ( ActionEvent e ) { } } private void registerNodeContextMenu ( BundleContext context , CyNodeViewContextMenuFactory myNodeViewContextMenuFactory ) { } public void registerMenu ( BundleContext context , String parentMenu , AbstractAction action ) { } private MarrsProject getBundledProject ( ) throws IOException , JDOMException { } public void loadPreviousProject ( ) { } }

Fix:
defaultValues . put ( MARRS_DRIVER . name ( ) , "Empty<seq2seq4repair_space>Jena<seq2seq4repair_space>Model" ) ;
Buggy code:
public class PackageDeclarationPattern extends SearchPattern { protected char [ ] pkgName ; public PackageDeclarationPattern ( char [ ] pkgName , int matchMode , boolean isCaseSensitive ) { } <START_BUG> public void findIndexMatches ( IndexInput input , IIndexSearchRequestor requestor , int detailLevel , IProgressMonitor progressMonitor , IJavaSearchScope scope ) { <END_BUG> } public String toString ( ) { } }

Fix:
public void findIndexMatches ( IndexInput input , IIndexSearchRequestor requestor , IProgressMonitor progressMonitor , IJavaSearchScope scope ) {
Buggy code:
public class JcrAclNodeHelper implements IAclNodeHelper { private static final Log logger = LogFactory . getLog ( JcrAclNodeHelper . class ) ; private static final String IS_ACL_NODE = "IS_ACL_NODE" ; private static final String TARGET = "TARGET" ; private final IUnifiedRepository unifiedRepository ; public JcrAclNodeHelper ( IUnifiedRepository unifiedRepository ) { } private boolean hasAclNode ( final RepositoryFile file ) { } private RepositoryFile getAclNode ( final RepositoryFile file ) { } @ Override public boolean canAccess ( final RepositoryFile repositoryFile , final EnumSet < RepositoryFilePermission > permissions ) { boolean hasAclNode = hasAclNode ( repositoryFile ) ; if ( ! hasAclNode ) { return true ; } final RepositoryFile aclNode = getAclNode ( repositoryFile ) ; try { <START_BUG> unifiedRepository . getFile ( aclNode . getPath ( ) ) ; <END_BUG> } catch ( Exception e ) { JcrAclNodeHelper . logger . warn ( "Error<seq2seq4repair_space>checking<seq2seq4repair_space>access<seq2seq4repair_space>for<seq2seq4repair_space>file" , e ) ; return false ; } return unifiedRepository . hasAccess ( aclNode . getPath ( ) , permissions ) ; } @ Override public RepositoryFileAcl getAclFor ( final RepositoryFile repositoryFile ) { } @ Override public void setAclFor ( final RepositoryFile fileToAddAclFor , final RepositoryFileAcl acl ) { } private RepositoryFile createAclNode ( RepositoryFile fileToAddAclFor ) { } @ Override public void removeAclFor ( RepositoryFile file ) { } }

Fix:
unifiedRepository . getFileById ( aclNode . getId ( ) ) ;
Buggy code:
public class Snippet137 { public static void main ( String [ ] args ) { String html = "<html><head>" + ( ( "<base<seq2seq4repair_space>href=\"http:////www.eclipse.org//swt//\"<seq2seq4repair_space>>" + "<title>HTML<seq2seq4repair_space>Test<//title><//head>" ) + "<body><a<seq2seq4repair_space>href=\"faq.php\">local<seq2seq4repair_space>link<//a><//body><//html>" ) ; Display display = new Display ( ) ; Shell shell = new Shell ( display ) ; shell . setLayout ( new FillLayout ( ) ) ; Browser browser ; try { browser = new Browser ( shell , SWT . NONE ) ; } catch ( SWTError e ) { <START_BUG> System . out . println ( ( "Count<seq2seq4repair_space>not<seq2seq4repair_space>instantiate<seq2seq4repair_space>Browser:<seq2seq4repair_space>" + ( e . getMessage ( ) ) ) ) ; <END_BUG> return ; } browser . setText ( html ) ; shell . open ( ) ; while ( ! ( shell . isDisposed ( ) ) ) { if ( ! ( display . readAndDispatch ( ) ) ) display . sleep ( ) ; } display . dispose ( ) ; } }

Fix:
System . out . println ( ( "Could<seq2seq4repair_space>not<seq2seq4repair_space>instantiate<seq2seq4repair_space>Browser:<seq2seq4repair_space>" + ( e . getMessage ( ) ) ) ) ;
Buggy code:
public class DataCenter extends BaseObject { private static final long serialVersionUID = - 5241720601365197280L ; final Map < String , StorageDomain > storageDomainMap = new HashMap < String , StorageDomain > ( ) ; String masterStorageDomainId ; Integer masterVersion = 0 ; String poolStatus = "connected" ; StorageType storageType = StorageType . NFS ; public Map < String , StorageDomain > getStorageDomainMap ( ) { } public String getMasterStorageDomainId ( ) { <START_BUG> return masterStorageDomainId ; <END_BUG> } public void setMasterStorageDomainId ( String masterStorageDomainId ) { } public Integer getMasterVersion ( ) { } public void setMasterVersion ( Integer masterVersion ) { } public String getPoolStatus ( ) { } public void setPoolStatus ( String poolStatus ) { } public StorageType getStorageType ( ) { } public void setStorageType ( StorageType storageType ) { } }

Fix:
return ( masterStorageDomainId ) == null ? this . id : masterStorageDomainId ;
Buggy code:
public class Disassembler extends ClassFileBytesDisassembler { private static final char [ ] ANY_EXCEPTION = Util . bind ( "classfileformat.anyexceptionhandler" ) . toCharArray ( ) ; private static final String EMPTY_OUTPUT = "" ; private static final String VERSION_UNKNOWN = "unknown" ; private void decodeModifiersForField ( StringBuffer buffer , int accessFlags ) { } private final void decodeModifiersForInnerClasses ( StringBuffer buffer , int accessFlags ) { } private final void decodeModifiersForMethod ( StringBuffer buffer , int accessFlags ) { } private final void decodeModifiersForType ( StringBuffer buffer , int accessFlags ) { } private String decodeStringValue ( String s ) { } public String disassemble ( byte [ ] classFileBytes , String lineSeparator ) throws ClassFormatException { } public String disassemble ( byte [ ] classFileBytes , String lineSeparator , int mode ) throws ClassFormatException { } public String disassemble ( IClassFileReader classFileReader , String lineSeparator ) { } public String disassemble ( IClassFileReader classFileReader , String lineSeparator , int mode ) { } private void disassemble ( IInnerClassesAttribute innerClassesAttribute , StringBuffer buffer , String lineSeparator , int tabNumber ) { } private void disassemble ( IFieldInfo fieldInfo , StringBuffer buffer , String lineSeparator , int tabNumber , int mode ) { } private void disassemble ( IClassFileReader classFileReader , IMethodInfo methodInfo , StringBuffer buffer , String lineSeparator , int tabNumber , int mode ) { } private void disassemble ( IClassFileAttribute classFileAttribute , StringBuffer buffer , String lineSeparator , int tabNumber ) { } private void disassemble ( ICodeAttribute codeAttribute , StringBuffer buffer , String lineSeparator , int tabNumber ) { } private void disassemble ( IEnclosingMethodAttribute enclosingMethodAttribute , StringBuffer buffer , String lineSeparator , int tabNumber ) { } private void disassembleTypeMembers ( IClassFileReader classFileReader , StringBuffer buffer , String lineSeparator , int tabNumber , int mode ) { } private final void dumpTab ( int tabNumber , StringBuffer buffer ) { for ( int i = 0 ; i < tabNumber ; i ++ ) { <START_BUG> buffer . append ( Util . bind ( "disassembler.identation" ) ) ; <END_BUG> } } public String getDescription ( ) { } private IEnclosingMethodAttribute getEnclosingMethodAttribute ( IClassFileReader classFileReader ) { } private ILocalVariableTableEntry getEntryFor ( int localIndex , ILocalVariableTableEntry [ ] entries ) { } private ILocalVariableTypeTableAttribute getLocalVariableTypeAttribute ( ICodeAttribute codeAttribute ) { } private char [ ] getSignatureForField ( char [ ] fieldDescriptor ) { } private boolean isDeprecated ( IClassFileReader classFileReader ) { } private boolean isSynthetic ( IClassFileReader classFileReader ) { } private char [ ] [ ] getParameterNames ( char [ ] methodDescriptor , ICodeAttribute codeAttribute , int accessFlags ) { } private void writeNewLine ( StringBuffer buffer , String lineSeparator , int tabNumber ) { } }

Fix:
buffer . append ( Util . bind ( "disassembler.indentation" ) ) ;
Buggy code:
public class ProposalFragment extends BaseFragment { private MaterialListView proposal_material_list_view ; private List < Movie > proposalList = new ArrayList < > ( ) ; private String account ; private SharedPreferences preferences ; private Editor editor ; public static ProposalFragment newInstance ( ) { } public ProposalFragment ( ) { } @ Override protected String getTagLog ( ) { } @ Override protected int getLayoutResourceId ( ) { } @ Override public View onCreateView ( LayoutInflater inflater , ViewGroup container , Bundle savedInstanceState ) { } private void parseResponse ( JSONObject response ) { } private void drawResult ( ) { } private void get ( String url ) { } private void addWatched ( String url , String id ) { } private boolean aDayIsPassed ( ) { preferences = getActivity ( ) . getPreferences ( MODE_PRIVATE ) ; Calendar c = Calendar . getInstance ( ) ; long now = c . getTimeInMillis ( ) ; long yday = preferences . getLong ( "PENDING_TIME" , 0 ) ; long diff = now - yday ; <START_BUG> if ( diff > 86400000 ) <END_BUG> return true ; else return false ; } @ Override public void onSaveInstanceState ( Bundle toSave ) { } No newline ; at end ; of file ; }

Fix:
if ( diff > 72000000 )
Buggy code:
public class ExecuteOn extends ExecTask { protected Vector filesets = new Vector ( ) ; private boolean parallel = false ; public void addFileset ( FileSet set ) { } public void addFilesetref ( Reference ref ) { } public void setParallel ( boolean parallel ) { } protected void checkConfiguration ( ) { } protected void runExec ( Execute exe ) throws BuildException { try { Vector v = new Vector ( ) ; for ( int i = 0 ; i < ( filesets . size ( ) ) ; i ++ ) { Object o = filesets . elementAt ( i ) ; FileSet fs = null ; if ( o instanceof FileSet ) { fs = ( ( FileSet ) ( o ) ) ; } else { Reference r = ( ( Reference ) ( o ) ) ; o = r . getReferencedObject ( project ) ; if ( o instanceof FileSet ) { fs = ( ( FileSet ) ( o ) ) ; } else { String msg = ( r . getRefId ( ) ) + "<seq2seq4repair_space>doesn\'t<seq2seq4repair_space>denote<seq2seq4repair_space>a<seq2seq4repair_space>fileset" ; throw new BuildException ( msg , location ) ; } } DirectoryScanner ds = fs . getDirectoryScanner ( project ) ; String [ ] s = ds . getIncludedFiles ( ) ; for ( int j = 0 ; j < ( s . length ) ; j ++ ) { v . addElement ( new File ( fs . getDir ( ) , s [ j ] ) . getAbsolutePath ( ) ) ; } } String [ ] s = new String [ v . size ( ) ] ; v . copyInto ( s ) ; int err = - 1 ; String myos = System . getProperty ( "os.name" ) ; if ( parallel ) { <START_BUG> cmdl . addLine ( s ) ; <END_BUG> exe . setCommandline ( cmdl . getCommandline ( ) ) ; err = exe . execute ( ) ; if ( err != 0 ) { if ( failOnError ) { throw new BuildException ( ( "Exec<seq2seq4repair_space>returned:<seq2seq4repair_space>" + err ) , location ) ; } else { log ( ( "Result:<seq2seq4repair_space>" + err ) , MSG_ERR ) ; } } } else { String [ ] cmd = new String [ ( cmdl . size ( ) ) + 1 ] ; System . arraycopy ( cmdl . getCommandline ( ) , 0 , cmd , 0 , cmdl . size ( ) ) ; for ( int i = 0 ; i < ( s . length ) ; i ++ ) { cmd [ cmdl . size ( ) ] = s [ i ] ; exe . setCommandline ( cmd ) ; err = exe . execute ( ) ; if ( err != 0 ) { if ( failOnError ) { throw new BuildException ( ( "Exec<seq2seq4repair_space>returned:<seq2seq4repair_space>" + err ) , location ) ; } else { log ( ( "Result:<seq2seq4repair_space>" + err ) , MSG_ERR ) ; } } } } } catch ( IOException e ) { throw new BuildException ( ( "Execute<seq2seq4repair_space>failed:<seq2seq4repair_space>" + e ) , e , location ) ; } finally { logFlush ( ) ; } } }

Fix:
cmdl . addArguments ( s ) ;