nus-yam/ex-repair huggingface dataset:
Buggy code:
public class HibernateStatisticsResource extends PlaceholderResource . PlaceholderResourceEntry { private final String puName ; private final PersistenceUnitServiceRegistry persistenceUnitRegistry ; private final ModelNode model = new ModelNode ( ) ; private final String providerLabel ; public HibernateStatisticsResource ( final String puName , final PersistenceUnitServiceRegistry persistenceUnitRegistry , final String providerLabel ) { } @ Override public ModelNode getModel ( ) { } @ Override public boolean isModelDefined ( ) { } @ Override public boolean hasChild ( PathElement element ) { } @ Override public Resource getChild ( PathElement element ) { } @ Override public Resource requireChild ( PathElement element ) { } @ Override public boolean hasChildren ( String childType ) { } @ Override public Resource navigate ( PathAddress address ) { } @ Override public Set < String > getChildTypes ( ) { } @ Override public Set < String > getChildrenNames ( String childType ) { } @ Override public Set < ResourceEntry > getChildren ( String childType ) { } @ Override public void registerChild ( PathElement address , Resource resource ) { } @ Override public Resource removeChild ( PathElement address ) { } @ Override public boolean isRuntime ( ) { } @ Override public boolean isProxy ( ) { } @ Override public HibernateStatisticsResource clone ( ) { } private boolean hasEntity ( PathElement element ) { } private Set < String > getEntityNames ( ) { } private boolean hasCacheRegion ( PathElement element ) { } private Set < String > getCacheRegionNames ( ) { final Statistics stats = getStatistics ( ) ; if ( stats == null ) { return Collections . emptySet ( ) ; } else { Set < String > result = new HashSet < String > ( ) ; String [ ] cacheRegionNames = stats . getSecondLevelCacheRegionNames ( ) ; if ( cacheRegionNames != null ) { for ( String region : cacheRegionNames ) { int stripUpTo = ( puName . length ( ) ) + 1 ; <START_BUG> if ( stripUpTo > 0 ) { <END_BUG> result . add ( region . substring ( stripUpTo ) ) ; } else { result . add ( region ) ; } } } return result ; } } private boolean hasQuery ( PathElement element ) { } private Set < String > getQueryNames ( ) { } private boolean hasCollection ( PathElement element ) { } private Set < String > getCollectionNames ( ) { } private Statistics getStatistics ( ) { } }

Fix:
if ( ( stripUpTo > 0 ) && ( stripUpTo < ( region . length ( ) ) ) ) {
Buggy code:
@ Controller @ RequestMapping ( "report" ) public class ReportController { @ Resource private JiraReportService jiraReportService ; @ RequestMapping ( value = "" , method = RequestMethod . GET ) public String showReportBoard ( Model model ) throws JiraException { model . addAttribute ( "rapidViews" , this . jiraReportService . loadRapidViews ( ) ) ; <START_BUG> model . addAttribute ( "sprints" , this . jiraReportService . loadRapidViewSprints ( 24 ) ) ; <END_BUG> return "report//reportBoard" ; } @ ResponseBody @ RequestMapping ( value = "loadRapidViewSprint" , method = RequestMethod . POST ) public List < Sprint > loadRapidViewSprint ( Model model , HttpServletRequest request ) throws JiraException { } @ RequestMapping ( value = "generateSprintReport" , method = RequestMethod . GET ) public String generateSprintReport ( Model model , HttpServletRequest request ) throws JiraException { } }

Fix:
model . addAttribute ( "sprints" , this . jiraReportService . loadRapidViewSprints ( 23 ) ) ;
Buggy code:
public class ParamAction extends Action { static String NO_NAME = "No<seq2seq4repair_space>name<seq2seq4repair_space>attribute<seq2seq4repair_space>in<seq2seq4repair_space><param><seq2seq4repair_space>element" ; static String NO_VALUE = "No<seq2seq4repair_space>name<seq2seq4repair_space>attribute<seq2seq4repair_space>in<seq2seq4repair_space><param><seq2seq4repair_space>element" ; boolean inError = false ; public void begin ( ExecutionContext ec , String localName , Attributes attributes ) { String name = attributes . getValue ( NAME_ATTRIBUTE ) ; String value = attributes . getValue ( VALUE_ATTRIBUTE ) ; if ( name == null ) { inError = true ; getLogger ( ) . error ( ParamAction . NO_NAME ) ; ec . addError ( new ErrorItem ( ParamAction . NO_NAME ) ) ; return ; } if ( value == null ) { inError = true ; getLogger ( ) . error ( ParamAction . NO_VALUE ) ; ec . addError ( new ErrorItem ( ParamAction . NO_VALUE ) ) ; return ; } value = value . trim ( ) ; Object o = ec . peekObject ( ) ; PropertySetter propSetter = new PropertySetter ( o ) ; <START_BUG> value = ec . subst ( OptionConverter . convertSpecialChars ( value ) ) ; <END_BUG> name = ec . subst ( name ) ; getLogger ( ) . debug ( "In<seq2seq4repair_space>ParamAction<seq2seq4repair_space>setting<seq2seq4repair_space>parameter<seq2seq4repair_space>[{}]<seq2seq4repair_space>to<seq2seq4repair_space>value<seq2seq4repair_space>[{}]." , name , value ) ; propSetter . setProperty ( name , value ) ; } public void end ( ExecutionContext ec , String localName ) { } public void finish ( ExecutionContext ec ) { } }

Fix:
value = ec . subst ( value ) ;
Buggy code:
public class SnowizardErrorTest { private static final ObjectMapper MAPPER = Jackson . newObjectMapper ( ) ; private final SnowizardError error = new SnowizardError ( 123 , "this<seq2seq4repair_space>is<seq2seq4repair_space>bad" ) ; @ Test public void serializesToJSON ( ) throws Exception { } @ Test public void deserializesFromJSON ( ) throws Exception { final SnowizardError actual = SnowizardErrorTest . MAPPER . readValue ( FixtureHelpers . fixture ( "fixtures//error.json" ) , SnowizardError . class ) ; <START_BUG> assertThat ( actual ) . isEqualsToByComparingFields ( error ) ; <END_BUG> } @ Test public void testEquals ( ) { } @ Test public void testToString ( ) { } @ Test public void testHashCode ( ) { } }

Fix:
assertThat ( actual ) . isEqualTo ( error ) ;
Buggy code:
public final class InvalidCAttributeUsageError extends ErroneousIssue { private static final ErrorCode _CODE = ErrorCode . onlyInstance ( INVALID_CATTRIBUTE_USAGE ) ; public static final Code CODE = InvalidCAttributeUsageError . _CODE ; private final String description ; public static InvalidCAttributeUsageError invalidScope ( ) { } public static InvalidCAttributeUsageError usageInGenericComponent ( ) { } public static InvalidCAttributeUsageError usageForNescObject ( ) { } public static InvalidCAttributeUsageError internalLinkage ( ) { } public static InvalidCAttributeUsageError appliedToAttribute ( ) { } public static InvalidCAttributeUsageError appliedToUnnamedTag ( ) { <START_BUG> final String description = "NesC<seq2seq4repair_space>attribute<seq2seq4repair_space>'@C()'<seq2seq4repair_space>cannot<seq2seq4repair_space>be<seq2seq4repair_space>applied<seq2seq4repair_space>to<seq2seq4repair_space>an<seq2seq4repair_space>unnamed<seq2seq4repair_space>tag<seq2seq4repair_space>declaration" ; <END_BUG> return new InvalidCAttributeUsageError ( description ) ; } private InvalidCAttributeUsageError ( String description ) { } @ Override public String generateDescription ( ) { } }

Fix:
final String description = "NesC<seq2seq4repair_space>attribute<seq2seq4repair_space>'@C()'<seq2seq4repair_space>cannot<seq2seq4repair_space>be<seq2seq4repair_space>applied<seq2seq4repair_space>to<seq2seq4repair_space>an<seq2seq4repair_space>anonymous<seq2seq4repair_space>tag" ;
Buggy code:
public class ForbidOveridingManagedDependenciesRule extends AbstractFilterableRule { public void execute ( EnforcerRuleHelper helper ) throws EnforcerRuleException { Log log = helper . getLog ( ) ; try { MavenProject project = getProject ( helper ) ; compareDependencyManagementWithParent ( project , log , new DifferenceHandler ( ) { public void handleDifference ( Log log , Dependency dependency , Dependency parentDependency ) { logHeader ( log , "dependency<seq2seq4repair_space>management" ) ; log . warn ( ( "Difference<seq2seq4repair_space>for:<seq2seq4repair_space>" + ( dependency . getManagementKey ( ) ) ) ) ; log . warn ( ( "Project:<seq2seq4repair_space>" + ( dependency . getVersion ( ) ) ) ) ; log . warn ( ( "Parent:<seq2seq4repair_space>" + ( parentDependency . getVersion ( ) ) ) ) ; log . warn ( "----------------------------------------" ) ; failureDetected = true ; } } ) ; <START_BUG> if ( ( isShouldBuildFail ( ) ) && ( failureDetected ) ) { <END_BUG> throw new EnforcerRuleException ( "Failing<seq2seq4repair_space>because<seq2seq4repair_space>of<seq2seq4repair_space>overridden<seq2seq4repair_space>managed<seq2seq4repair_space>dependencies" ) ; } } catch ( ExpressionEvaluationException e ) { throw new EnforcerRuleException ( ( "Unable<seq2seq4repair_space>to<seq2seq4repair_space>lookup<seq2seq4repair_space>an<seq2seq4repair_space>expression<seq2seq4repair_space>" + ( e . getLocalizedMessage ( ) ) ) , e ) ; } } }

Fix:
if ( ( shouldBuildFail ( ) ) && ( failureDetected ) ) {
Buggy code:
public class TestAtomicUpdate extends LuceneTestCase { private static final Analyzer ANALYZER = new SimpleAnalyzer ( ) ; private static final Random RANDOM = new Random ( ) ; private abstract static class TimedThread extends Thread { boolean failed ; int count ; private static int RUN_TIME_SEC = 3 ; private TestAtomicUpdate . TimedThread [ ] allThreads ; public abstract void doWork ( ) throws Throwable { } TimedThread ( TestAtomicUpdate . TimedThread [ ] threads ) { } public void run ( ) { } private boolean anyErrors ( ) { } } private static class IndexerThread extends TestAtomicUpdate . TimedThread { IndexWriter writer ; public int count ; public IndexerThread ( IndexWriter writer , TestAtomicUpdate . TimedThread [ ] threads ) { } public void doWork ( ) throws Exception { } } private static class SearcherThread extends TestAtomicUpdate . TimedThread { private Directory directory ; public SearcherThread ( Directory directory , TestAtomicUpdate . TimedThread [ ] threads ) { } public void doWork ( ) throws Throwable { } } public void runTest ( Directory directory ) throws Exception { } public void testAtomicUpdates ( ) throws Exception { Directory directory ; directory = new MockRAMDirectory ( ) ; runTest ( directory ) ; directory . close ( ) ; String tempDir = System . getProperty ( "java.io.tmpdir" ) ; File dirPath = new File ( tempDir , "lucene.test.atomic" ) ; <START_BUG> directory = FSDirectory . getDirectory ( dirPath , null , false ) ; <END_BUG> runTest ( directory ) ; directory . close ( ) ; _TestUtil . rmDir ( dirPath ) ; } }

Fix:
directory = FSDirectory . getDirectory ( dirPath ) ;
Buggy code:
public class Exit extends Platform { private static String exitText ; public void act ( ) { } private void checkForPlayer ( ) { <START_BUG> Actor player = ( ( Actor ) ( getOneObjectAtOffset ( 0 , ( ( - ( getImage ( ) . getHeight ( ) ) ) // 2 ) , Player . class ) ) ) ; <END_BUG> if ( ( player != null ) && ( ( Scorekeeper . getScore ( ) ) >= 3 ) ) { Greenfoot . playSound ( "heavy.mp3" ) ; getWorld ( ) . showText ( Exit . exitText , ( ( getWorld ( ) . getWidth ( ) ) // 2 ) , ( ( getWorld ( ) . getHeight ( ) ) // 2 ) ) ; Greenfoot . delay ( 100 ) ; GameWorld . incrementLevel ( ) ; ( ( GameWorld ) ( getWorld ( ) ) ) . changeLevel ( ) ; } } public static void setText ( String text ) { } public static String getText ( ) { } }

Fix:
Actor player = ( ( Actor ) ( getOneObjectAtOffset ( 0 , ( ( ( - ( getImage ( ) . getHeight ( ) ) ) // 2 ) - 2 ) , Player . class ) ) ) ;
Buggy code:
@ Deprecated public class ConfigProviderModule extends PrivateModule { static final Logger log = LoggerFactory . getLogger ( ConfigProviderModule . class ) ; private final ConfigProvider provider ; public ConfigProviderModule ( HierarchicalConfiguration configuration ) { } @ Override protected void configure ( ) { bind ( ConfigProvider . class ) . toInstance ( provider ) ; expose ( ConfigProvider . class ) ; ZookeeperConfig zkCfg = provider . getConfig ( ZookeeperConfig . class ) ; bind ( ZookeeperConfig . class ) . toInstance ( zkCfg ) ; expose ( ZookeeperConfig . class ) ; ConfigProviderModule . log . info ( "config<seq2seq4repair_space>start<seq2seq4repair_space>-----------------------" ) ; <START_BUG> Map < String , Object > allConf = new TreeMap ( provider . getAll ( ) ) ; <END_BUG> for ( Map . Entry < String , Object > confValue : allConf . entrySet ( ) ) { ConfigProviderModule . log . info ( "<seq2seq4repair_space>{}<seq2seq4repair_space>=<seq2seq4repair_space>{}" , confValue . getKey ( ) , confValue . getValue ( ) ) ; } ConfigProviderModule . log . info ( "config<seq2seq4repair_space>end<seq2seq4repair_space>--------------------------" ) ; } }

Fix:
Map < String , Object > allConf = new java . util . TreeMap ( provider . getAll ( ) ) ;
Buggy code:
@ Service ( "jPushRegister" ) public class JPushRegister { protected Logger logger = Logger . getLogger ( this . getClass ( ) ) ; @ SuppressWarnings ( "rawtypes" ) @ Resource private RedisTemplate redisTemplate ; private static final String namespace = "com.haalthy.service.JPush.reg." ; @ SuppressWarnings ( "unchecked" ) public void Register ( final String userName , final String jPushID ) { redisTemplate . execute ( new org . springframework . data . redis . core . RedisCallback < String > ( ) { @ Override public String doInRedis ( RedisConnection connection ) throws DataAccessException { byte [ ] btyKey = redisTemplate . getStringSerializer ( ) . serialize ( ( ( JPushRegister . namespace ) + userName ) ) ; byte [ ] btyField = redisTemplate . getStringSerializer ( ) . serialize ( "pushID" ) ; byte [ ] btyBody = redisTemplate . getStringSerializer ( ) . serialize ( jPushID ) ; <START_BUG> connection . hSetNX ( btyKey , btyField , btyBody ) ; <END_BUG> connection . expire ( btyKey , 6048000 ) ; return null ; } } ) ; } @ SuppressWarnings ( "unchecked" ) public Object GetJPushID ( final String userName ) { } }

Fix:
connection . hSet ( btyKey , btyField , btyBody ) ;
Buggy code:
public class Server { private static final Logger logger = Logger . getLogger ( "org.jboss.as.server" ) ; private final ServerEnvironment environment ; private ServerCommunicationHandler serverCommunicationHandler ; private final MessageHandler messageHandler = new MessageHandler ( this ) ; private Standalone config ; private ServiceContainer serviceContainer ; public Server ( ServerEnvironment environment ) { } public void start ( Standalone config ) throws ServerStartException { } public void stop ( ) { } private void launchCommunicationHandler ( ) { <START_BUG> this . serverCommunicationHandler = ServerCommunicationHandlerFactory . getInstance ( ) . getServerCommunicationHandler ( environment , messageHandler ) ; <END_BUG> Thread t = new Thread ( this . serverCommunicationHandler . getController ( ) , "Server<seq2seq4repair_space>Process" ) ; t . start ( ) ; } private void sendMessage ( final String message ) { } }

Fix:
this . serverCommunicationHandler = ServerCommunicationHandlerFactory . getInstance ( ) . getProcessManagerSlave ( environment , messageHandler ) ;
Buggy code:
class TableTab extends ScrollableTab { Table table1 ; Group tableGroup ; Group itemGroup ; Button checkButton ; Button fullSelectionButton ; Button hideSelectionButton ; Button multipleColumns ; Button moveableColumns ; Button headerVisibleButton ; Button linesVisibleButton ; Button itemForegroundButton ; Button itemBackgroundButton ; Button itemFontButton ; Color itemForegroundColor ; Color itemBackgroundColor ; Image itemForegroundImage ; Image itemBackgroundImage ; Font itemFont ; static String [ ] columnTitles = new String [ ] { ControlExample . getResourceString ( "TableTitle_0" ) , ControlExample . getResourceString ( "TableTitle_1" ) , ControlExample . getResourceString ( "TableTitle_2" ) , ControlExample . getResourceString ( "TableTitle_3" ) } ; static String [ ] [ ] tableData = new String [ ] [ ] { new String [ ] { ControlExample . getResourceString ( "TableLine0_0" ) , ControlExample . getResourceString ( "TableLine0_1" ) , ControlExample . getResourceString ( "TableLine0_2" ) , ControlExample . getResourceString ( "TableLine0_3" ) } , new String [ ] { ControlExample . getResourceString ( "TableLine1_0" ) , ControlExample . getResourceString ( "TableLine1_1" ) , ControlExample . getResourceString ( "TableLine1_2" ) , ControlExample . getResourceString ( "TableLine1_3" ) } , new String [ ] { ControlExample . getResourceString ( "TableLine2_0" ) , ControlExample . getResourceString ( "TableLine2_1" ) , ControlExample . getResourceString ( "TableLine2_2" ) , ControlExample . getResourceString ( "TableLine2_3" ) } } ; TableTab ( ControlExample instance ) { } void createColorGroup ( ) { } void createOtherGroup ( ) { } void createExampleGroup ( ) { super . createExampleGroup ( ) ; tableGroup = new Group ( exampleGroup , SWT . NONE ) ; tableGroup . setLayout ( new GridLayout ( ) ) ; <START_BUG> tableGroup . setLayoutData ( new GridData ( ( ( ( GridData . GRAB_HORIZONTAL ) | ( GridData . HORIZONTAL_ALIGN_FILL ) ) | ( GridData . VERTICAL_ALIGN_FILL ) ) ) ) ; <END_BUG> tableGroup . setText ( "Table" ) ; } void createExampleWidgets ( ) { } void setItemText ( TableItem item , int i , String node ) { } void createStyleGroup ( ) { } Item [ ] getExampleWidgetItems ( ) { } Control [ ] getExampleWidgets ( ) { } String [ ] getMethodNames ( ) { } String setMethodName ( String methodRoot ) { } Object [ ] parameterForType ( String typeName , String value , Control control ) { } TableItem findItem ( String value , TableItem [ ] items ) { } String getTabText ( ) { } void resetColorsAndFonts ( ) { } void setItemBackground ( ) { } void setItemForeground ( ) { } void setItemFont ( ) { } void setExampleWidgetFont ( ) { } void packColumns ( ) { } void setColumnsMoveable ( ) { } void setExampleWidgetState ( ) { } void setWidgetHeaderVisible ( ) { } void setWidgetLinesVisible ( ) { } }

Fix:
tableGroup . setLayoutData ( new GridData ( SWT . FILL , SWT . FILL , true , true ) ) ;
Buggy code:
public class EclipseScope implements IScope { private Scope scope ; private EclipseFactory world ; private ResolvedType enclosingType ; private FormalBinding [ ] bindings ; private String [ ] importedPrefixes = null ; private String [ ] importedNames = null ; public EclipseScope ( FormalBinding [ ] bindings , Scope scope ) { } public UnresolvedType lookupType ( String name , IHasPosition location ) { <START_BUG> char [ ] [ ] splitName = WildTypePattern . splitNames ( name ) ; <END_BUG> TypeBinding b = scope . getType ( splitName , splitName . length ) ; if ( ! ( b . isValidBinding ( ) ) ) { return ResolvedType . MISSING ; } return world . fromBinding ( b ) ; } private void computeImports ( ) { } private void addClassAndParentsToPrefixes ( ReferenceBinding binding , List importedPrefixesList ) { } public String [ ] getImportedNames ( ) { } public String [ ] getImportedPrefixes ( ) { } public FormalBinding lookupFormal ( String name ) { } public FormalBinding getFormal ( int i ) { } public int getFormalCount ( ) { } public ISourceLocation makeSourceLocation ( IHasPosition location ) { } public IMessageHandler getMessageHandler ( ) { } public void message ( IMessage . Kind kind , IHasPosition location1 , IHasPosition location2 , String message ) { } public void message ( IMessage . Kind kind , IHasPosition location , String message ) { } public void message ( IMessage aMessage ) { } public World getWorld ( ) { } public ResolvedType getEnclosingType ( ) { } }

Fix:
char [ ] [ ] splitName = WildTypePattern . splitNames ( name , true ) ;
Buggy code:
public class Palette extends Panel { private static final long serialVersionUID = 1L ; private IModel choicesModel ; private IChoiceRenderer choiceRenderer ; private int rows ; private boolean allowOrder ; private Recorder recorderComponent ; private Component choicesComponent ; private Component selectionComponent ; private static final PackageResourceReference javascript = new PackageResourceReference ( Palette . class , "palette.js" ) ; private static final PackageResourceReference upImage = new PackageResourceReference ( Palette . class , "up.gif" ) ; private static final PackageResourceReference downImage = new PackageResourceReference ( Palette . class , "down.gif" ) ; private static final PackageResourceReference removeImage = new PackageResourceReference ( Palette . class , "remove.gif" ) ; private static final PackageResourceReference addImage = new PackageResourceReference ( Palette . class , "add.gif" ) ; public Palette ( String id , IModel model , IModel choicesModel , IChoiceRenderer choiceRenderer , int rows , boolean allowOrder ) { } private void addJavascript ( ) { IModel srcReplacement = new Model ( ) { private static final long serialVersionUID = 1L ; public Object getObject ( Component component ) { <START_BUG> String url = getPage ( ) . urlFor ( Palette . javascript ) ; <END_BUG> return url ; } } ; WebMarkupContainer javascript = new WebMarkupContainer ( "javascript" ) ; javascript . add ( new wicket . AttributeModifier ( "src" , true , srcReplacement ) ) ; add ( javascript ) ; } public Iterator getSelectedChoices ( ) { } public Iterator getUnselectedChoices ( ) { } private Recorder newRecorderComponent ( ) { } protected Component newAvailableHeader ( ) { } protected Component newSelectedHeader ( ) { } protected Component newDownComponent ( ) { } protected Component newUpComponent ( ) { } protected Component newRemoveComponent ( ) { } protected Component newAddComponent ( ) { } protected Component newSelectionComponent ( ) { } protected Component newChoicesComponent ( ) { } private Component getChoicesComponent ( ) { } private Component getSelectionComponent ( ) { } private Recorder getRecorderComponent ( ) { } public Collection getChoices ( ) { } public Collection getModelCollection ( ) { } public IChoiceRenderer getChoiceRenderer ( ) { } public int getRows ( ) { } protected final void updateModel ( ) { } protected String buildJSCall ( String funcName ) { } public String getChoicesOnFocusJS ( ) { } public String getSelectionOnFocusJS ( ) { } public String getAddOnClickJS ( ) { } public String getRemoveOnClickJS ( ) { } public String getUpOnClickJS ( ) { } public String getDownOnClickJS ( ) { } protected void internalOnEndRequest ( ) { } }

Fix:
String url = urlFor ( Palette . javascript ) ;
Buggy code:
public class And implements TruthState { private ArrayList < TruthState > elements ; public And ( ) { } public And ( ArrayList < TruthState > elements ) { } @ Override public TruthState cloneDeep ( ) { } @ Override public boolean proven ( KnowledgeBase kb ) { } @ Override public boolean disproven ( KnowledgeBase kb ) { } @ Override public ArrayList < TruthState > backwardChain ( KnowledgeBase kb ) { } public ArrayList < TruthState > copyLists ( ArrayList < TruthState > lists , int cnt ) { } public void add ( TruthState ts ) { } @ Override public String toString ( ) { } @ Override public double factsUsefulness ( HashMap < String , String > facts ) { if ( ( elements . size ( ) ) == 0 ) return 0 ; <START_BUG> int factsProven = 0 ; <END_BUG> Iterator < TruthState > es = elements . iterator ( ) ; while ( es . hasNext ( ) ) { factsProven += es . next ( ) . factsUsefulness ( facts ) ; } return ( ( double ) ( factsProven ) ) // ( elements . size ( ) ) ; } }

Fix:
double factsProven = 0 ;
Buggy code:
class RemoveFolderFromIndex extends IndexRequest { IPath folderPath ; char [ ] [ ] inclusionPatterns ; char [ ] [ ] exclusionPatterns ; IProject project ; public RemoveFolderFromIndex ( IPath folderPath , char [ ] [ ] inclusionPatterns , char [ ] [ ] exclusionPatterns , IProject project , IndexManager manager ) { } public boolean execute ( IProgressMonitor progressMonitor ) { if ( ( this . isCancelled ) || ( ( progressMonitor != null ) && ( progressMonitor . isCanceled ( ) ) ) ) return true ; <START_BUG> Index index = manager . getIndex ( this . containerPath , true , false ) ; <END_BUG> if ( index == null ) return true ; ReadWriteMonitor monitor = index . monitor ; if ( monitor == null ) return true ; try { monitor . enterRead ( ) ; String [ ] paths = index . queryDocumentNames ( this . folderPath . toString ( ) ) ; if ( ( ( this . exclusionPatterns ) == null ) && ( ( this . inclusionPatterns ) == null ) ) { for ( int i = 0 , max = ( paths == null ) ? 0 : paths . length ; i < max ; i ++ ) manager . remove ( paths [ i ] , this . containerPath ) ; } else { for ( int i = 0 , max = ( paths == null ) ? 0 : paths . length ; i < max ; i ++ ) { String documentPath = paths [ i ] ; if ( ! ( Util . isExcluded ( new Path ( documentPath ) , this . inclusionPatterns , this . exclusionPatterns , false ) ) ) manager . remove ( documentPath , this . containerPath ) ; } } } catch ( IOException e ) { if ( JobManager . VERBOSE ) { Util . verbose ( ( ( "-><seq2seq4repair_space>failed<seq2seq4repair_space>to<seq2seq4repair_space>remove<seq2seq4repair_space>" + ( this . folderPath ) ) + "<seq2seq4repair_space>from<seq2seq4repair_space>index<seq2seq4repair_space>because<seq2seq4repair_space>of<seq2seq4repair_space>the<seq2seq4repair_space>following<seq2seq4repair_space>exception:" ) , System . err ) ; e . printStackTrace ( ) ; } return false ; } finally { monitor . exitRead ( ) ; } return true ; } public String toString ( ) { } }

Fix:
Index index = this . manager . getIndex ( this . containerPath , true , false ) ;
Buggy code:
public abstract class Geosphere extends Surface { public static int heatDistributionCount ; public static int thermalInc ; public static float averageVolcanicMass ; private long strataBuoyancyStamp ; public Geosphere ( int worldSize , int surfaceDelay , int threadsDelay , int threadCount ) { } public void addToSurface ( Layer type , float amount ) { } public void depositSediment ( int x , int y ) { float maxPressure ; long age ; GeoCell cell = getCellAt ( x , y ) ; <START_BUG> cell . getSedimentBuffer ( ) . applySedimentBuffer ( ) ; <END_BUG> formNewRock ( cell , calcDepth ( SEDIMENT , 9.8F , 400 ) ) ; age = cell . getAge ( ) ; if ( age > 1.0E8 ) { maxPressure = 886655 ; } else { maxPressure = ( ( float ) ( Math . exp ( ( ( - ( ( age - 7.1792856098E8 ) // 5.0E7 ) ) + 25000 ) ) ) ) ; } melt ( cell , calcDepth ( cell . getDensity ( ) , 9.8F , maxPressure ) ) ; } public void melt ( GeoCell cell , float maxHeight ) { } public void formNewRock ( GeoCell cell , float maxHeight ) { } public void spreadToLowest ( GeoCell spreadFrom ) { } public void convertTopLayer ( GeoCell spreadFrom , float height ) { } public void getLowestCells ( GeoCell spreadFrom , List < GeoCell > lowestList , int max ) { } public void spread ( ArrayList < GeoCell > lowestList , GeoCell spreadFrom ) { } public void updateLavaFlows ( int x , int y ) { } public boolean checkForGeologicalUpdate ( ) { } private void stampBuoyancyTimeStamp ( ) { } public void updateGeology ( int x , int y ) { } private void geologicalUpdate ( GeoCell cell ) { } public void heatMantel ( ) { } public void dust ( GeoCell cell ) { } }

Fix:
cell . getSedimentBuffer ( ) . applyBuffer ( ) ;
Buggy code:
public class Aj implements ClassPreProcessor { private IWeavingContext weavingContext ; public Aj ( ) { } public Aj ( IWeavingContext context ) { } public void initialize ( ) { } public byte [ ] preProcess ( String className , byte [ ] bytes , ClassLoader loader ) { if ( ( loader == null ) || ( className == null ) ) { return bytes ; } try { WeavingAdaptor weavingAdaptor = Aj . WeaverContainer . getWeaver ( loader , weavingContext ) ; if ( weavingAdaptor == null ) { return bytes ; } return weavingAdaptor . weaveClass ( className , bytes ) ; <START_BUG> } catch ( Throwable t ) { <END_BUG> t . printStackTrace ( ) ; return bytes ; } } static class WeaverContainer { private static Map weavingAdaptors = new WeakHashMap ( ) ; static WeavingAdaptor getWeaver ( ClassLoader loader , IWeavingContext weavingContext ) { } } static class ExplicitlyInitializedClassLoaderWeavingAdaptor { private final ClassLoaderWeavingAdaptor weavingAdaptor ; private boolean isInitialized ; public ExplicitlyInitializedClassLoaderWeavingAdaptor ( ClassLoaderWeavingAdaptor weavingAdaptor ) { } private void initialize ( ClassLoader loader , IWeavingContext weavingContext ) { } public ClassLoaderWeavingAdaptor getWeavingAdaptor ( ClassLoader loader , IWeavingContext weavingContext ) { } } public String getNamespace ( ClassLoader loader ) { } public boolean generatedClassesExist ( ClassLoader loader ) { } public void flushGeneratedClasses ( ClassLoader loader ) { } }

Fix:
} catch ( Exception t ) {
Buggy code:
public class SOClient { IContainer container = null ; ISharedObjectContainer socontainer = null ; ID targetID = null ; protected void setupContainer ( String type ) throws Exception { <START_BUG> container = ContainerFactory . getDefault ( ) . makeContainer ( type ) ; <END_BUG> socontainer = ( ( ISharedObjectContainer ) ( container . getAdapter ( ISharedObjectContainer . class ) ) ) ; } }

Fix:
container = ContainerFactory . getDefault ( ) . createContainer ( type ) ;
Buggy code:
public class AuditResourceDefinition extends SimpleResourceDefinition { public static final AuditResourceDefinition INSTANCE = new AuditResourceDefinition ( ) ; private AuditResourceDefinition ( ) { } @ Override public void registerChildren ( ManagementResourceRegistration resourceRegistration ) { super . registerChildren ( resourceRegistration ) ; <START_BUG> resourceRegistration . registerSubModel ( new MappingModuleDefinition ( Constants . PROVIDER ) ) ; <END_BUG> } static class AuditResourceDefinitionAdd extends SecurityDomainReloadAddHandler { static final AuditResourceDefinition . AuditResourceDefinitionAdd INSTANCE = new AuditResourceDefinition . AuditResourceDefinitionAdd ( ) ; @ Override protected void populateModel ( ModelNode operation , ModelNode model ) throws OperationFailedException { } } }

Fix:
resourceRegistration . registerSubModel ( new MappingProviderModuleDefinition ( Constants . PROVIDER_MODULE ) ) ;
Buggy code:
public class JSONUnmarshaller { private static final String EXCEPTION_CAST_MESSAGE = "Value<seq2seq4repair_space>for<seq2seq4repair_space>field<seq2seq4repair_space>'%1$s'<seq2seq4repair_space>can<seq2seq4repair_space>not<seq2seq4repair_space>be<seq2seq4repair_space>cast<seq2seq4repair_space>from<seq2seq4repair_space>%2$s<seq2seq4repair_space>to<seq2seq4repair_space>%3$s" ; public static < O > O unmarshall ( JSONObject json , Class < O > c ) { O instance = null ; try { instance = c . newInstance ( ) ; Field [ ] fields = c . getDeclaredFields ( ) ; for ( Field field : fields ) { field . setAccessible ( true ) ; JSONElement eleAnno = field . getAnnotation ( JSONElement . class ) ; if ( eleAnno != null ) { Object value = json . opt ( eleAnno . name ( ) ) ; if ( value != null ) { if ( value instanceof JSONArray ) { value = JSONUnmarshaller . unmarshallJSONArray ( ( ( JSONArray ) ( value ) ) , field , instance ) ; } else if ( value instanceof JSONObject ) { <START_BUG> value = JSONUnmarshaller . unmarshall ( ( ( JSONObject ) ( value ) ) , c ) ; <END_BUG> } JSONUnmarshaller . setValueToField ( field , value , instance ) ; } } field . setAccessible ( false ) ; } } catch ( InstantiationException ex ) { Logger . getLogger ( JSONUnmarshaller . class . getName ( ) ) . log ( Level . SEVERE , null , ex ) ; } catch ( IllegalAccessException ex ) { Logger . getLogger ( JSONUnmarshaller . class . getName ( ) ) . log ( Level . SEVERE , null , ex ) ; } return instance ; } private static void setValueToField ( Field f , Object value , Object instance ) throws IllegalAccessException , IllegalArgumentException { } private static Object unmarshallJSONArray ( JSONArray array , Field f , Object instance ) { } }

Fix:
value = JSONUnmarshaller . unmarshall ( ( ( JSONObject ) ( value ) ) , field . getType ( ) ) ;
Buggy code:
public class ContextImpl extends Context { private Entity entity ; private ContextImpl parent ; private VariableResolverImpl resolver ; private DataSource ds ; private int currProcess ; private Map < String , Object > requestParams ; private DataImporter dataImporter ; private Map < String , Object > entitySession ; private Map < String , Object > globalSession ; private Map < String , Object > docSession ; public ContextImpl ( DataConfig . Entity entity , VariableResolverImpl resolver , DataSource ds , int currProcess , Map < String , Object > requestParams , Map < String , Object > global , ContextImpl p , DataImporter di ) { } public String getEntityAttribute ( String name ) { } public List < Map < String , String > > getAllEntityFields ( ) { } public VariableResolver getVariableResolver ( ) { } public DataSource getDataSource ( ) { } public DataSource getDataSource ( String name ) { } public boolean isRootEntity ( ) { } public int currentProcess ( ) { } public Map < String , Object > getRequestParameters ( ) { } public EntityProcessor getEntityProcessor ( ) { } public void setSessionAttribute ( String name , Object val , String scope ) { } public Object getSessionAttribute ( String name , String scope ) { } public Context getParentContext ( ) { } public Map < String , Object > getDocSession ( ) { } public void setDocSession ( Map < String , Object > docSession ) { } public SolrCore getSolrCore ( ) { <START_BUG> return dataImporter . getCore ( ) ; <END_BUG> } }

Fix:
return ( dataImporter ) == null ? null : dataImporter . getCore ( ) ;
Buggy code:
public class Main extends Application { XStream xStream = new XStream ( ) ; TrainingEngine engine = null ; MainController mainController = null ; Stage primaryStage ; @ Override public void start ( Stage primaryStage ) throws Exception { this . primaryStage = primaryStage ; FXMLLoader loader = new FXMLLoader ( ) ; loader . setLocation ( getClass ( ) . getResource ( "//uixml//main.fxml" ) ) ; BorderPane root = loader . load ( ) ; mainController = loader . getController ( ) ; mainController . setMain ( this ) ; <START_BUG> primaryStage . setTitle ( "FROG测试" ) ; <END_BUG> primaryStage . setScene ( new Scene ( root ) ) ; primaryStage . show ( ) ; engine = new TrainingEngine ( ) ; loadHumans ( ) ; } @ Override public void stop ( ) throws Exception { } public static void main ( String [ ] args ) { } public Human showAddPeopleDialogue ( ) { } private Human newHuman ( String name ) { } private void loadHumans ( ) { } }

Fix:
primaryStage . setTitle ( "Face<seq2seq4repair_space>Recognition<seq2seq4repair_space>Image<seq2seq4repair_space>Library<seq2seq4repair_space>in<seq2seq4repair_space>Java,<seq2seq4repair_space>FriL" ) ;
Buggy code:
public class PageModule extends Module { public PageModule ( ) { } @ Override public String getStatistics ( ) throws IOException { StringBuilder stats = new StringBuilder ( 256 ) ; stats . append ( ( ( "The<seq2seq4repair_space>maximum<seq2seq4repair_space>depth<seq2seq4repair_space>of<seq2seq4repair_space>the<seq2seq4repair_space>webpage<seq2seq4repair_space>is:<seq2seq4repair_space>" + ( PageModule . maxTreeDepth ( document ) ) ) + "\n" ) ) ; stats . append ( pageSize ( url ) ) ; <START_BUG> return null ; <END_BUG> } public static int maxTreeDepth ( Element root ) { } public String getHeaders ( ) { } public String pageSize ( String pagename ) throws IOException { } private String hrbCount ( long bytes , boolean si ) { } }

Fix:
return stats . toString ( ) ;
Buggy code:
public class Home extends ListActivity { private Intent intent ; private Context context ; @ Override public void onCreate ( Bundle savedInstanceState ) { super . onCreate ( savedInstanceState ) ; context = getApplicationContext ( ) ; Intent serviceIntent = new Intent ( this , UpdaterService . class ) ; startService ( serviceIntent ) ; String [ ] listItems = new String [ ] { "AbeyuGroup" , "main<seq2seq4repair_space>" , "test123" } ; setListAdapter ( new android . widget . ArrayAdapter < String > ( this , layout . simple_list_item_1 , listItems ) ) ; <START_BUG> intent = new Intent ( this , LifeLines . class ) ; <END_BUG> getListView ( ) . setOnItemClickListener ( new OnItemClickListener ( ) { public void onItemClick ( AdapterView < ? > parent , View view , int position , long id ) { startActivity ( intent ) ; Toast . makeText ( getApplicationContext ( ) , ( ( android . widget . TextView ) ( view ) ) . getText ( ) , LENGTH_SHORT ) . show ( ) ; } } ) ; } @ Override public boolean onCreateOptionsMenu ( Menu menu ) { } public boolean onOptionsItemSelected ( MenuItem item ) { } }

Fix:
intent = new Intent ( this , AddLifeLine . class ) ;
Buggy code:
public class ItemEnderPearlReusable extends ItemEnderUtilities { @ SideOnly ( Side . CLIENT ) private IIcon eliteIcon ; public ItemEnderPearlReusable ( ) { } @ Override public String getUnlocalizedName ( ItemStack stack ) { } @ Override public ItemStack onItemRightClick ( ItemStack stack , World world , EntityPlayer player ) { if ( ( world . isRemote ) == true ) { return stack ; } EntityEnderPearlReusable pearl = new EntityEnderPearlReusable ( world , player , ( ( stack . getItemDamage ( ) ) == 1 ) ) ; if ( ( stack . getItemDamage ( ) ) == 1 ) { Entity bottomEntity = EntityUtils . getBottomEntity ( player ) ; if ( ( bottomEntity instanceof EntityEnderPearlReusable ) && ( ( bottomEntity . riddenByEntity ) != null ) ) { bottomEntity . riddenByEntity . mountEntity ( null ) ; } <START_BUG> bottomEntity . mountEntity ( pearl ) ; <END_BUG> } -- ( stack . stackSize ) ; world . spawnEntityInWorld ( pearl ) ; world . playSoundAtEntity ( player , "random.bow" , 0.5F , ( 0.4F // ( ( ( itemRand . nextFloat ( ) ) * 0.4F ) + 0.8F ) ) ) ; return stack ; } @ Override @ SideOnly ( Side . CLIENT ) public void getSubItems ( Item item , CreativeTabs creativeTab , List list ) { } @ Override @ SideOnly ( Side . CLIENT ) public void registerIcons ( IIconRegister iconRegister ) { } @ SideOnly ( Side . CLIENT ) @ Override public IIcon getIconFromDamage ( int damage ) { } }

Fix:
EntityUtils . getBottomEntity ( player ) . mountEntity ( pearl ) ;
Buggy code:
public class JettyWebSocketListenerAdapter implements WebSocketListener { private static final Log logger = LogFactory . getLog ( JettyWebSocketListenerAdapter . class ) ; private final WebSocketHandler webSocketHandler ; private JettyWebSocketSessionAdapter wsSession ; public JettyWebSocketListenerAdapter ( WebSocketHandler webSocketHandler , JettyWebSocketSessionAdapter wsSession ) { } @ Override public void onWebSocketConnect ( Session session ) { } @ Override public void onWebSocketText ( String payload ) { } @ Override public void onWebSocketBinary ( byte [ ] payload , int offset , int len ) { <START_BUG> BinaryMessage message = new BinaryMessage ( payload , offset , len ) ; <END_BUG> try { this . webSocketHandler . handleMessage ( this . wsSession , message ) ; } catch ( Throwable t ) { ExceptionWebSocketHandlerDecorator . tryCloseWithError ( this . wsSession , t , JettyWebSocketListenerAdapter . logger ) ; } } @ Override public void onWebSocketClose ( int statusCode , String reason ) { } @ Override public void onWebSocketError ( Throwable cause ) { } }

Fix:
BinaryMessage message = new BinaryMessage ( payload , offset , len , true ) ;
Buggy code:
public abstract class BaseController < E > { @ ExceptionHandler ( ObjectNotFoundException . class ) @ ResponseStatus ( HttpStatus . NOT_FOUND ) @ ResponseBody protected Response < E > objectNotFoundHandler ( ObjectNotFoundException e ) { } @ ExceptionHandler ( { ConstraintViolationException . class , DataIntegrityViolationException . class } ) @ ResponseStatus ( HttpStatus . CONFLICT ) @ ResponseBody protected Response < E > dataIntegrityViolationHandler ( ) { } @ ExceptionHandler ( MethodArgumentNotValidException . class ) @ ResponseStatus ( HttpStatus . BAD_REQUEST ) @ ResponseBody protected Response < E > invalidArgumentHandler ( MethodArgumentNotValidException ex ) { Response < E > response = new Response ( ) ; for ( ObjectError validationError : ex . getBindingResult ( ) . getAllErrors ( ) ) { FieldError fieldError = ( ( FieldError ) ( validationError ) ) ; <START_BUG> ValidationError error = new ValidationError ( fieldError . getField ( ) , fieldError . getDefaultMessage ( ) ) ; <END_BUG> response . addError ( error ) ; } return response ; } protected < T > ResponseEntity < List < T > > toResponse ( List < T > entities ) { } }

Fix:
Error error = new Error ( fieldError . getField ( ) , fieldError . getDefaultMessage ( ) ) ;
Buggy code:
public class _Suite extends BaseTestCase { static final String OLD_RELEASE_PATH_PROPERTY = "derbyTesting.oldReleasePath" ; static final String OLD_JAR_URL = "https:////svn.apache.org//repos//asf//db//derby//jars" ; private static final int [ ] [ ] OLD_VERSIONS = new int [ ] [ ] { new int [ ] { 10 , 0 , 2 , 1 } , new int [ ] { 10 , 1 , 1 , 0 } , new int [ ] { 10 , 1 , 2 , 1 } , new int [ ] { 10 , 1 , 3 , 1 } , new int [ ] { 10 , 2 , 1 , 6 } , new int [ ] { 10 , 2 , 2 , 0 } } ; private _Suite ( String name ) { } public static Test suite ( ) { TestSuite suite = new TestSuite ( "Upgrade<seq2seq4repair_space>Suite" ) ; for ( int i = 0 ; i < ( _Suite . OLD_VERSIONS . length ) ; i ++ ) { <START_BUG> if ( ! ( ( ( JDBC . vmSupportsJSR169 ( ) ) && ( ( _Suite . OLD_VERSIONS [ i ] [ 0 ] ) == 10 ) ) && ( ( _Suite . OLD_VERSIONS [ i ] [ 1 ] ) == 0 ) ) ) ; <END_BUG> suite . addTest ( UpgradeRun . suite ( _Suite . OLD_VERSIONS [ i ] ) ) ; } return suite ; } }

Fix:
if ( ! ( ( ( JDBC . vmSupportsJSR169 ( ) ) && ( ( _Suite . OLD_VERSIONS [ i ] [ 0 ] ) == 10 ) ) && ( ( _Suite . OLD_VERSIONS [ i ] [ 1 ] ) == 0 ) ) )
Buggy code:
public class PlayerListener { MChat plugin ; public PlayerListener ( MChat instance ) { } @ Subscribe ( order = Order . EARLY ) public void onPlayerJoin ( PlayerJoinEvent event ) { final Player player = event . getPlayer ( ) ; String world = player . getWorld ( ) . getName ( ) ; UUID uuid = player . getUniqueId ( ) ; if ( INFO_ADD_NEW_PLAYERS . getBoolean ( ) ) { if ( ConfigManager . getConfig ( INFO_HOCON ) . getConfig ( ) . getNode ( ( "users." + uuid ) ) . isVirtual ( ) ) { Writer . addBase ( uuid . toString ( ) , USER ) ; } } if ( MCHAT_ALTER_LIST . getBoolean ( ) ) { <START_BUG> event . getGame ( ) . getScheduler ( ) . runTaskAfter ( plugin , new Runnable ( ) { <END_BUG> public void run ( ) { setCustomName ( player ) ; } } , 20L ) ; } if ( MCHAT_ALTER_EVENTS . getBoolean ( ) ) { if ( SUPPRESS_USE_JOIN . getBoolean ( ) ) { suppressEventMessage ( Parser . parseEvent ( uuid , world , JOIN ) , "mchat.suppress.join" , "mchat.bypass.suppress.join" , SUPPRESS_MAX_JOIN . getInteger ( ) ) ; event . setJoinMessage ( Messages . builder ( "" ) . build ( ) ) ; } else { event . setJoinMessage ( Messages . builder ( Parser . parseEvent ( uuid , world , JOIN ) ) . build ( ) ) ; } } } @ Subscribe ( order = Order . EARLY ) public void onPlayerQuit ( PlayerQuitEvent event ) { } private void suppressEventMessage ( String format , String permNode , String overrideNode , Integer max ) { } private void setCustomName ( Player player ) { } No newline ; at end ; of file ; }

Fix:
event . getGame ( ) . getSyncScheduler ( ) . runTaskAfter ( plugin , new Runnable ( ) {
Buggy code:
public class XSImplementationImpl extends CoreDOMImplementationImpl implements XSImplementation { static XSImplementationImpl singleton = new XSImplementationImpl ( ) ; public static DOMImplementation getDOMImplementation ( ) { } public boolean hasFeature ( String feature , String version ) { } public XSLoader createXSLoader ( StringList versions ) throws XSException { <START_BUG> XSLoader loader = new XMLSchemaLoader ( ) ; <END_BUG> if ( versions == null ) { return loader ; } for ( int i = 0 ; i < ( versions . getLength ( ) ) ; i ++ ) { if ( ! ( versions . item ( i ) . equals ( "1.0" ) ) ) { String msg = DOMMessageFormatter . formatMessage ( DOM_DOMAIN , "FEATURE_NOT_SUPPORTED" , new Object [ ] { versions . item ( i ) } ) ; throw new XSException ( XSException . NOT_SUPPORTED_ERR , msg ) ; } } return loader ; } public StringList getRecognizedVersions ( ) { } }

Fix:
XSLoader loader = new XSLoaderImpl ( ) ;
Buggy code:
public class SmartSEOS3Client { private static final Log _log = LogFactory . getLog ( SmartSEOS3Client . class ) ; private static URI getS3ContentURI ( Configuration config , SubjectType subjectType , ContentType contentType , int page , boolean staging , String productID ) throws URISyntaxException { } private static String getSmartSEOContentHTTP ( Configuration config , SubjectType subjectType , ContentType contentType , int page , boolean staging , String productID ) { String smartSEOPayload ; try { URI targetUrl = SmartSEOS3Client . getS3ContentURI ( config , subjectType , contentType , page , staging , productID ) ; SmartSEOS3Client . _log . debug ( ( "Fetching<seq2seq4repair_space>:<seq2seq4repair_space>" + targetUrl ) ) ; int connectionTimeout = Integer . parseInt ( config . get ( CONNECT_TIMEOUT ) ) ; int socketTimeout = Integer . parseInt ( config . get ( SOCKET_TIMEOUT ) ) ; <START_BUG> smartSEOPayload = Request . Get ( targetUrl ) . connectTimeout ( connectionTimeout ) . socketTimeout ( socketTimeout ) . execute ( ) . returnContent ( ) . asString ( ) ; <END_BUG> } catch ( ClientProtocolException e ) { SmartSEOS3Client . _log . error ( "Unable<seq2seq4repair_space>to<seq2seq4repair_space>download<seq2seq4repair_space>SmartSEO<seq2seq4repair_space>content<seq2seq4repair_space>via<seq2seq4repair_space>HTTP." , e ) ; throw new BVSEOException ( "Unable<seq2seq4repair_space>to<seq2seq4repair_space>download<seq2seq4repair_space>SmartSEO<seq2seq4repair_space>content<seq2seq4repair_space>from<seq2seq4repair_space>S3." ) ; } catch ( IOException e ) { SmartSEOS3Client . _log . error ( "Unable<seq2seq4repair_space>to<seq2seq4repair_space>download<seq2seq4repair_space>SmartSEO<seq2seq4repair_space>content<seq2seq4repair_space>via<seq2seq4repair_space>HTTP." , e ) ; throw new BVSEOException ( "Unable<seq2seq4repair_space>to<seq2seq4repair_space>download<seq2seq4repair_space>SmartSEO<seq2seq4repair_space>content<seq2seq4repair_space>from<seq2seq4repair_space>S3." ) ; } catch ( URISyntaxException e ) { SmartSEOS3Client . _log . error ( "Unable<seq2seq4repair_space>to<seq2seq4repair_space>download<seq2seq4repair_space>SmartSEO<seq2seq4repair_space>content<seq2seq4repair_space>via<seq2seq4repair_space>HTTP.<seq2seq4repair_space>Invalid<seq2seq4repair_space>URL." , e ) ; throw new BVSEOException ( "Unable<seq2seq4repair_space>to<seq2seq4repair_space>download<seq2seq4repair_space>SmartSEO<seq2seq4repair_space>content<seq2seq4repair_space>via<seq2seq4repair_space>HTTP.<seq2seq4repair_space>Invalid<seq2seq4repair_space>URL." ) ; } return smartSEOPayload ; } private static String getSmartSEOContentFilesystem ( Configuration config , SubjectType subjectType , ContentType contentType , int page , String productID ) { } public static String getSmartSEOContent ( Configuration config , String pageURL , SubjectType subjectType , ContentType contentType , int page , boolean staging , String productID ) { } }

Fix:
smartSEOPayload = new String ( Request . Get ( targetUrl ) . connectTimeout ( connectionTimeout ) . socketTimeout ( socketTimeout ) . execute ( ) . returnContent ( ) . asBytes ( ) ) ;
Buggy code:
public class CliClient { private Client thriftClient_ = null ; private CliSessionState css_ = null ; public CliClient ( CliSessionState css , Cassandra . Client thriftClient ) { } public void executeCLIStmt ( String stmt ) throws InvalidRequestException , NotFoundException , TException , UnavailableException { } private void printCmdHelp ( ) { } private void cleanupAndExit ( ) { } private void executeGet ( CommonTree ast ) throws InvalidRequestException , NotFoundException , TException { } private void executeSet ( CommonTree ast ) throws InvalidRequestException , TException , UnavailableException { } private void executeShowProperty ( CommonTree ast , String propertyName ) throws TException { } private void executeShowTables ( CommonTree ast ) throws TException { } private void executeDescribeTable ( CommonTree ast ) throws TException { } private void executeConnect ( CommonTree ast ) throws TException { int portNumber = Integer . parseInt ( ast . getChild ( 1 ) . getText ( ) ) ; Tree idList = ast . getChild ( 0 ) ; <START_BUG> StringBuffer hostName = new StringBuffer ( ) ; <END_BUG> int idCount = idList . getChildCount ( ) ; for ( int idx = 0 ; idx < idCount ; idx ++ ) { hostName . append ( idList . getChild ( idx ) . getText ( ) ) ; } CliMain . disconnect ( ) ; css_ . hostName = hostName . toString ( ) ; css_ . thriftPort = portNumber ; CliMain . connect ( css_ . hostName , css_ . thriftPort ) ; } public void executeQueryOnServer ( String query ) throws TException { } }

Fix:
StringBuilder hostName = new StringBuilder ( ) ;