nus-yam/ex-repair huggingface dataset:
Buggy code:
public class CodeSnippetReturnStatement extends ReturnStatement implements InvocationSite , EvaluationConstants { MethodBinding setResultMethod ; public CodeSnippetReturnStatement ( Expression expr , int s , int e , EvaluationContext evaluationContext ) { } public FlowInfo analyseCode ( BlockScope currentScope , FlowContext flowContext , FlowInfo flowInfo ) { } public void generateReturnBytecode ( BlockScope currentScope , CodeStream codeStream ) { } public void generateStoreSaveValueIfNecessary ( BlockScope currentScope , CodeStream codeStream ) { codeStream . aload_0 ( ) ; if ( ( ( this . expression ) == null ) || ( ( this . expressionType ) == ( VoidBinding ) ) ) { codeStream . aconst_null ( ) ; codeStream . generateClassLiteralAccessForType ( VoidBinding , null ) ; } else { int valueTypeID = this . expressionType . id ; if ( ( valueTypeID == ( TypeIds . T_long ) ) || ( valueTypeID == ( TypeIds . T_double ) ) ) { codeStream . dup_x2 ( ) ; codeStream . pop ( ) ; } else { codeStream . swap ( ) ; } if ( this . expressionType . isBaseType ( ) ) { <START_BUG> codeStream . generateObjectWrapperForType ( this . expressionType ) ; <END_BUG> } codeStream . generateClassLiteralAccessForType ( this . expressionType , null ) ; } codeStream . invokevirtual ( this . setResultMethod ) ; } public boolean isSuperAccess ( ) { } public boolean isTypeAccess ( ) { } public boolean needValue ( ) { } public void prepareSaveValueLocation ( BlockScope currentScope ) { } public void resolve ( BlockScope scope ) { } public void setDepth ( int depth ) { } public void setFieldIndex ( int depth ) { } }

Fix:
( ( CodeSnippetCodeStream ) ( codeStream ) ) . generateObjectWrapperForType ( this . expressionType ) ;
Buggy code:
public class RecipeViewHelper extends EditorPart { public RecipeViewHelper ( ) { } @ Override public void doSave ( IProgressMonitor monitor ) { } @ Override public void doSaveAs ( ) { } @ Override public void init ( IEditorSite site , IEditorInput input ) throws PartInitException { } @ Override public boolean isDirty ( ) { } @ Override public boolean isSaveAsAllowed ( ) { } @ Override public void createPartControl ( Composite parent ) { if ( ( getEditorInput ( ) ) instanceof IPathEditorInput ) { IPathEditorInput pei = ( ( IPathEditorInput ) ( getEditorInput ( ) ) ) ; IFile file = ResourcesPlugin . getWorkspace ( ) . getRoot ( ) . getFile ( pei . getPath ( ) ) ; new OpenRecipesAction ( file ) . run ( null ) ; try { <START_BUG> getSite ( ) . getPage ( ) . showView ( "org.openarchitectureware.eclipse.recipeBrowser.RecipeBrowserView" ) ; <END_BUG> } catch ( PartInitException e ) { RecipePlugin . log ( e . getStatus ( ) ) ; } } new org . eclipse . ui . progress . UIJob ( "Close<seq2seq4repair_space>editor" ) { @ Override public org . eclipse . core . runtime . IStatus runInUIThread ( IProgressMonitor monitor ) { getSite ( ) . getPage ( ) . closeEditor ( RecipeViewHelper . this , false ) ; return org . eclipse . core . runtime . Status . OK_STATUS ; } } . schedule ( ) ; } @ Override public void setFocus ( ) { } }

Fix:
getSite ( ) . getPage ( ) . showView ( "org.eclipse.m2t.common.recipe.recipeBrowser.RecipeBrowserView" ) ;
Buggy code:
public class DefaultItemReuseStrategy implements IItemReuseStrategy { private static final long serialVersionUID = 1L ; private static final IItemReuseStrategy instance = new DefaultItemReuseStrategy ( ) ; public static IItemReuseStrategy getInstance ( ) { } public Iterator getItems ( final IItemFactory factory , final Iterator newModels , final Iterator existingItems ) { return new Iterator ( ) { private int index = 0 ; public void remove ( ) { throw new UnsupportedOperationException ( ) ; } public boolean hasNext ( ) { return newModels . hasNext ( ) ; } public Object next ( ) { Object next = newModels . next ( ) ; <START_BUG> if ( ! ( next instanceof IModel ) ) <END_BUG> throw new WicketRuntimeException ( ( ( ( "Expecting<seq2seq4repair_space>an<seq2seq4repair_space>instance<seq2seq4repair_space>of<seq2seq4repair_space>" + ( IModel . class . getName ( ) ) ) + ",<seq2seq4repair_space>got<seq2seq4repair_space>" ) + ( next . getClass ( ) . getName ( ) ) ) ) ; final IModel model = ( ( IModel ) ( next ) ) ; Item item = factory . newItem ( index , model ) ; ( index ) ++ ; return item ; } } ; } }

Fix:
if ( ( next != null ) && ( ! ( next instanceof IModel ) ) )
Buggy code:
public class PhysicalPortSerializer implements JsonSerializer < PhysicalPort > { @ Override public JsonElement serialize ( final PhysicalPort port , final Type portType , final JsonSerializationContext context ) { final JsonObject result = new JsonObject ( ) ; result . addProperty ( "dpid" , port . getParentSwitch ( ) . getSwitchName ( ) ) ; <START_BUG> result . addProperty ( "port" , String . valueOf ( port . getPortNumber ( ) ) ) ; <END_BUG> return result ; } }

Fix:
result . addProperty ( "port" , port . getPortNumber ( ) ) ;
Buggy code:
public class ScrollBar extends Widget { Scrollable parent ; ScrollBar ( ) { } ScrollBar ( Scrollable parent , int style ) { } public void addSelectionListener ( SelectionListener listener ) { } static int checkStyle ( int style ) { } void createHandle ( int index ) { } public boolean getEnabled ( ) { } public int getIncrement ( ) { } public int getMaximum ( ) { } public int getMinimum ( ) { } public int getPageIncrement ( ) { } public Scrollable getParent ( ) { } public int getSelection ( ) { } public Point getSize ( ) { } public int getThumb ( ) { } public boolean getVisible ( ) { } void hookEvents ( ) { } public boolean isEnabled ( ) { } public boolean isVisible ( ) { } void manageChildren ( ) { } void propagateWidget ( boolean enabled ) { } void releaseChild ( ) { } void releaseWidget ( ) { } public void removeSelectionListener ( SelectionListener listener ) { } void sendScrollEvent ( int detail ) { } public void setEnabled ( boolean enabled ) { } public void setIncrement ( int value ) { } public void setMaximum ( int value ) { } public void setMinimum ( int value ) { } public void setPageIncrement ( int value ) { } public void setSelection ( int selection ) { } public void setThumb ( int value ) { } public void setValues ( int selection , int minimum , int maximum , int thumb , int increment , int pageIncrement ) { } public void setVisible ( boolean visible ) { checkWidget ( ) ; <START_BUG> parent . setScrollbarVisible ( this , visible ) ; <END_BUG> } int XmNdecrementCallback ( int w , int client_data , int call_data ) { } int XmNdragCallback ( int w , int client_data , int call_data ) { } int XmNincrementCallback ( int w , int client_data , int call_data ) { } int XmNpageDecrementCallback ( int w , int client_data , int call_data ) { } int XmNpageIncrementCallback ( int w , int client_data , int call_data ) { } int XmNtoBottomCallback ( int w , int client_data , int call_data ) { } int XmNtoTopCallback ( int w , int client_data , int call_data ) { } int XmNvalueChangedCallback ( int w , int client_data , int call_data ) { } }

Fix:
parent . setScrollBarVisible ( this , visible ) ;
Buggy code:
public final class ValidationAjaxHandler extends DojoAjaxHandler { private static Log log = LogFactory . getLog ( ValidationAjaxHandler . class ) ; private final String eventName ; private FormComponent formComponent ; public ValidationAjaxHandler ( String eventName ) { } public final String getEventName ( ) { } public final void renderHeadContribution ( HtmlHeaderContainer container ) { } public final void onComponentTag ( final ComponentTag tag ) { final ValueMap attributes = tag . getAttributes ( ) ; <START_BUG> final String attributeValue = ( ( ( "javascript:validate('" + ( getCallbackUrl ( ) ) ) + "',<seq2seq4repair_space>'" ) + ( formComponent . getPath ( ) ) ) + "',<seq2seq4repair_space>this);" ; <END_BUG> attributes . put ( getEventName ( ) , attributeValue ) ; } protected final IResourceStream getResponse ( ) { } }

Fix:
final String attributeValue = ( ( ( "javascript:validate('" + ( getCallbackUrl ( ) ) ) + "',<seq2seq4repair_space>'" ) + ( formComponent . getInput ( ) ) ) + "',<seq2seq4repair_space>this);" ;
Buggy code:
public class JTLData implements Serializable , DataSet { protected final HashMap < String , SamplingStatCalculator > data = new HashMap < String , SamplingStatCalculator > ( ) ; protected String jtl_file = null ; protected long startTimestamp = 0 ; protected long endTimestamp = 0 ; protected File inputFile = null ; public JTLData ( ) { } public Set < ? > getURLs ( ) { } public Set < SamplingStatCalculator > getStats ( ) { } @ SuppressWarnings ( "unchecked" ) public List getStats ( List urls ) { } public void setDataSource ( String absolutePath ) { } public String getDataSource ( ) { } public String getDataSourceName ( ) { } public void setStartTimestamp ( long stamp ) { } public long getStartTimestamp ( ) { } public void setEndTimestamp ( long stamp ) { } public long getEndTimestamp ( ) { } public Date getDate ( ) { } public String getMonthDayDate ( ) { } public String getMonthDayYearDate ( ) { } public SamplingStatCalculator getStatistics ( String url ) { } public void loadData ( ) { } public void add ( SampleResult sample ) { if ( ( data . size ( ) ) == 0 ) { this . startTimestamp = sample . getStartTime ( ) ; } else { this . endTimestamp = sample . getEndTime ( ) ; } String url = sample . getSampleLabel ( ) ; if ( url == null ) { url = sample . getURL ( ) . toString ( ) ; } SamplingStatCalculator row = data . get ( url ) ; if ( row == null ) { <START_BUG> row = new SamplingStatCalculator ( ) ; <END_BUG> this . data . put ( url , row ) ; } row . addSample ( sample ) ; } public boolean isStats ( ) { } }

Fix:
row = new SamplingStatCalculator ( url ) ;
Buggy code:
public class ADB { private WMain wm = null ; private String adbFile = "" ; public ADB ( WMain wmain ) { } private void startADBD ( ) { try { <START_BUG> Runtime . getRuntime ( ) . exec ( "lib//adb//adb.exe<seq2seq4repair_space>fork-server<seq2seq4repair_space>server" ) ; <END_BUG> } catch ( IOException e ) { JOptionPane . showMessageDialog ( null , "ADB<seq2seq4repair_space>konnte<seq2seq4repair_space>nicht<seq2seq4repair_space>gefunden<seq2seq4repair_space>werden!" ) ; e . printStackTrace ( ) ; } } private void showError ( String error ) { } public boolean isConnected ( ) { } public String [ ] exec ( String command ) { } }

Fix:
Runtime . getRuntime ( ) . exec ( ( ( "lib//adb//" + ( adbFile ) ) + "<seq2seq4repair_space>fork-server<seq2seq4repair_space>server" ) ) ;
Buggy code:
@ CommandPermissions ( level = AdminLevel . OP , source = SourceType . BOTH , blockHostConsole = true ) @ CommandParameters ( description = "Sets<seq2seq4repair_space>gamemode<seq2seq4repair_space>to<seq2seq4repair_space>survival<seq2seq4repair_space>and<seq2seq4repair_space>gives<seq2seq4repair_space>diamond<seq2seq4repair_space>armor" , usage = "//<command><seq2seq4repair_space><playername>" ) public class Command_pvp extends TFM_Command { @ Override public boolean run ( CommandSender sender , Player sender_p , Command cmd , String commandLabel , String [ ] args , boolean senderIsConsole ) { if ( ( args . length ) != 0 ) { return false ; } Player player ; player = sender_p ; ItemStack dhelmet = new ItemStack ( Material . DIAMOND_HELMET ) ; ItemStack dchestplate = new ItemStack ( Material . DIAMOND_CHESTPLATE ) ; ItemStack dleggings = new ItemStack ( Material . DIAMOND_LEGGINGS ) ; ItemStack dboots = new ItemStack ( Material . DIAMOND_BOOTS ) ; ItemStack dsword = new ItemStack ( Material . DIAMOND_SWORD ) ; ItemStack gapple = new ItemStack ( Material . GOLDEN_APPLE ) ; player . getInventory ( ) . addItem ( new ItemStack [ ] { dhelmet , dchestplate , dleggings , dboots , dsword , gapple } ) ; player . setGameMode ( SURVIVAL ) ; <START_BUG> playerMsg ( "You<seq2seq4repair_space>have<seq2seq4repair_space>been<seq2seq4repair_space>given<seq2seq4repair_space>PVP<seq2seq4repair_space>items" ) ; <END_BUG> return true ; } No newline ; at end ; of file ; }

Fix:
playerMsg ( "You<seq2seq4repair_space>have<seq2seq4repair_space>been<seq2seq4repair_space>given<seq2seq4repair_space>PVP<seq2seq4repair_space>items<seq2seq4repair_space>and<seq2seq4repair_space>your<seq2seq4repair_space>gamemode<seq2seq4repair_space>was<seq2seq4repair_space>set<seq2seq4repair_space>to<seq2seq4repair_space>survival" ) ;
Buggy code:
public class LoadMetricDefinition extends SimpleResourceDefinition { static final PathElement PATH = PathElement . pathElement ( LOAD_METRIC ) ; protected static final LoadMetricDefinition INSTANCE = new LoadMetricDefinition ( ) ; static final SimpleAttributeDefinition TYPE = SimpleAttributeDefinitionBuilder . create ( CommonAttributes . TYPE , STRING , false ) . setAllowExpression ( false ) . setRestartAllServices ( ) . setValidator ( new org . jboss . as . controller . operations . validation . EnumValidator < LoadMetricEnum > ( LoadMetricEnum . class , false , false ) ) . build ( ) ; static final SimpleAttributeDefinition WEIGHT = SimpleAttributeDefinitionBuilder . create ( CommonAttributes . WEIGHT , INT , true ) . setAllowExpression ( true ) . setRestartAllServices ( ) . setDefaultValue ( new org . jboss . dmr . ModelNode ( LoadMetric . DEFAULT_WEIGHT ) ) . build ( ) ; static final SimpleAttributeDefinition CAPACITY = SimpleAttributeDefinitionBuilder . create ( CommonAttributes . CAPACITY , DOUBLE , true ) . setAllowExpression ( true ) . setRestartAllServices ( ) . setDefaultValue ( new org . jboss . dmr . ModelNode ( LoadMetric . DEFAULT_CAPACITY ) ) . build ( ) ; static final PropertiesAttributeDefinition PROPERTY = new PropertiesAttributeDefinition . Builder ( CommonAttributes . PROPERTY , true ) . setAllowExpression ( true ) . setRestartAllServices ( ) . build ( ) ; static final AttributeDefinition [ ] ATTRIBUTES = new AttributeDefinition [ ] { LoadMetricDefinition . TYPE , LoadMetricDefinition . WEIGHT , LoadMetricDefinition . CAPACITY , LoadMetricDefinition . PROPERTY } ; static void buildTransformation ( ModelVersion version , ResourceTransformationDescriptionBuilder builder ) { <START_BUG> if ( VERSION_1_3_0 . requiresTransformation ( version ) ) { <END_BUG> builder . addChildResource ( LoadMetricDefinition . PATH ) . getAttributeBuilder ( ) . addRejectCheck ( SIMPLE_EXPRESSIONS , LoadMetricDefinition . TYPE , LoadMetricDefinition . WEIGHT , LoadMetricDefinition . CAPACITY , LoadMetricDefinition . PROPERTY ) . addRejectCheck ( CapacityCheckerAndConverter . INSTANCE , LoadMetricDefinition . CAPACITY ) . setValueConverter ( CapacityCheckerAndConverter . INSTANCE , LoadMetricDefinition . CAPACITY ) . addRejectCheck ( PropertyCheckerAndConverter . INSTANCE , LoadMetricDefinition . PROPERTY ) . setValueConverter ( PropertyCheckerAndConverter . INSTANCE , LoadMetricDefinition . PROPERTY ) . end ( ) ; } } private LoadMetricDefinition ( ) { } @ Override public void registerAttributes ( ManagementResourceRegistration resourceRegistration ) { } }

Fix:
if ( VERSION_1_2_0 . requiresTransformation ( version ) ) {
Buggy code:
public class GZip extends Pack { protected void pack ( ) { GZIPOutputStream zOut = null ; try { zOut = new GZIPOutputStream ( new FileOutputStream ( zipFile ) ) ; zipFile ( source , zOut ) ; } catch ( IOException ioe ) { String msg = "Problem<seq2seq4repair_space>creating<seq2seq4repair_space>gzip<seq2seq4repair_space>" + ( ioe . getMessage ( ) ) ; <START_BUG> throw new org . apache . tools . ant . BuildException ( msg , ioe , location ) ; <END_BUG> } finally { if ( zOut != null ) { try { zOut . close ( ) ; } catch ( IOException e ) { } } } } }

Fix:
throw new org . apache . tools . ant . BuildException ( msg , ioe , getLocation ( ) ) ;
Buggy code:
public class StringToDoubleConverter extends AbstractConverter { private static final Resources REZ = ResourceManager . getPackageResources ( StringToDoubleConverter . class ) ; public StringToDoubleConverter ( ) { } <START_BUG> public Object convert ( final Object object , final Context context ) throws ConverterException { <END_BUG> try { return new Double ( ( ( String ) ( object ) ) ) ; } catch ( final NumberFormatException nfe ) { final String message = StringToDoubleConverter . REZ . getString ( "convert.bad-double.error" , object ) ; throw new ConverterException ( message , nfe ) ; } } }

Fix:
public Object convert ( final Object object , final Object context ) throws ConverterException {
Buggy code:
public class Snippet29 { public static void main ( String [ ] args ) { Display display = new Display ( ) ; Shell shell = new Shell ( display ) ; Menu bar = new Menu ( shell , SWT . BAR ) ; shell . setMenuBar ( bar ) ; MenuItem fileItem = new MenuItem ( bar , SWT . CASCADE ) ; fileItem . setText ( "File" ) ; Menu submenu = new Menu ( shell , SWT . DROP_DOWN ) ; fileItem . setMenu ( submenu ) ; MenuItem item = new MenuItem ( submenu , SWT . PUSH ) ; item . addListener ( Selection , new Listener ( ) { public void handleEvent ( Event e ) { System . out . println ( "Select<seq2seq4repair_space>All" ) ; } } ) ; item . setText ( "Select<seq2seq4repair_space>&All\tCtrl+A" ) ; <START_BUG> item . setAccelerator ( ( ( SWT . CTRL ) + 'A' ) ) ; <END_BUG> shell . setSize ( 200 , 200 ) ; shell . open ( ) ; while ( ! ( shell . isDisposed ( ) ) ) { if ( ! ( display . readAndDispatch ( ) ) ) display . sleep ( ) ; } display . dispose ( ) ; } }

Fix:
item . setAccelerator ( ( ( SWT . MOD1 ) + 'A' ) ) ;
Buggy code:
public class JSFExtension implements Extension { public static final String SUBSYSTEM_NAME = "jsf" ; public static final String NAMESPACE = "urn:jboss:domain:jsf:1.0" ; private static final JSFExtension . JSFSubsystemParser PARSER = new JSFExtension . JSFSubsystemParser ( ) ; private static final PathElement PATH_SUBSYSTEM = PathElement . pathElement ( SUBSYSTEM , JSFExtension . SUBSYSTEM_NAME ) ; private static final String RESOURCE_NAME = ( JSFExtension . class . getPackage ( ) . getName ( ) ) + ".LocalDescriptions" ; private static final int MANAGEMENT_API_MAJOR_VERSION = 1 ; private static final int MANAGEMENT_API_MINOR_VERSION = 0 ; private static final int MANAGEMENT_API_MICRO_VERSION = 0 ; static StandardResourceDescriptionResolver getResourceDescriptionResolver ( final String ... keyPrefix ) { } private static final ResourceDefinition JSF_SUBSYSTEM_RESOURCE = new org . jboss . as . controller . SimpleResourceDefinition ( JSFExtension . PATH_SUBSYSTEM , JSFExtension . getResourceDescriptionResolver ( ) , JSFSubsystemAdd . INSTANCE , ReloadRequiredRemoveStepHandler . INSTANCE ) ; @ Override public void initialize ( final ExtensionContext context ) { ROOT_LOGGER . debug ( "Activating<seq2seq4repair_space>JSF(Mojarra)<seq2seq4repair_space>Extension" ) ; final SubsystemRegistration subsystem = context . registerSubsystem ( JSFExtension . SUBSYSTEM_NAME , JSFExtension . MANAGEMENT_API_MAJOR_VERSION , JSFExtension . MANAGEMENT_API_MINOR_VERSION , JSFExtension . MANAGEMENT_API_MICRO_VERSION ) ; final ManagementResourceRegistration registration = subsystem . registerSubsystemModel ( JSFExtension . JSF_SUBSYSTEM_RESOURCE ) ; <START_BUG> registration . registerOperationHandler ( DESCRIBE , INSTANCE , INSTANCE , false , PRIVATE ) ; <END_BUG> subsystem . registerXMLElementWriter ( JSFExtension . PARSER ) ; } @ Override public void initializeParsers ( final ExtensionParsingContext context ) { } static class JSFSubsystemParser implements XMLStreamConstants , XMLElementReader < List < ModelNode > > , XMLElementWriter < SubsystemMarshallingContext > { @ Override public void readElement ( final XMLExtendedStreamReader reader , final List < ModelNode > list ) throws XMLStreamException { } @ Override public void writeContent ( final XMLExtendedStreamWriter streamWriter , final SubsystemMarshallingContext context ) throws XMLStreamException { } } }

Fix:
registration . registerOperationHandler ( DEFINITION , INSTANCE ) ;
Buggy code:
public class SelectOptions < T > extends RepeatingView { private static final long serialVersionUID = 1L ; private boolean recreateChoices = false ; private final IOptionRenderer < T > renderer ; public SelectOptions ( String id , IModel < Collection < ? extends T > > model , IOptionRenderer < T > renderer ) { } public SelectOptions ( String id , Collection < ? extends T > elements , IOptionRenderer < T > renderer ) { } public SelectOptions < T > setRecreateChoices ( boolean refresh ) { } @ SuppressWarnings ( "unchecked" ) @ Override protected final void onPopulate ( ) { if ( ( ( SelectOptions . size ( ) ) == 0 ) || ( recreateChoices ) ) { SelectOptions . removeAll ( ) ; Collection < ? extends T > modelObject = ( ( Collection < ? extends T > ) ( SelectOptions . getDefaultModelObject ( ) ) ) ; if ( modelObject != null ) { if ( ! ( modelObject instanceof Collection ) ) { throw new WicketRuntimeException ( ( ( "Model<seq2seq4repair_space>object<seq2seq4repair_space>" + modelObject ) + "<seq2seq4repair_space>not<seq2seq4repair_space>a<seq2seq4repair_space>collection" ) ) ; } Iterator < ? extends T > it = modelObject . iterator ( ) ; while ( it . hasNext ( ) ) { WebMarkupContainer row = new WebMarkupContainer ( SelectOptions . newChildId ( ) ) ; row . setRenderBodyOnly ( true ) ; add ( row ) ; <START_BUG> Object value = it . next ( ) ; <END_BUG> String text = renderer . getDisplayValue ( value ) ; IModel < T > model = renderer . getModel ( value ) ; row . add ( newOption ( text , model ) ) ; } } } } protected SelectOption < T > newOption ( String text , IModel < T > model ) { } private static class SimpleSelectOption < V > extends SelectOption < V > { private static final long serialVersionUID = 1L ; private final String text ; public SimpleSelectOption ( String id , IModel < V > model , String text ) { } @ Override protected void onComponentTagBody ( MarkupStream markupStream , ComponentTag openTag ) { } } }

Fix:
T value = it . next ( ) ;
Buggy code:
public class CFMetaDataParser extends XMLMetaDataParser { static final String [ ] PACKAGES = new String [ ] { "java.lang." , "java.util." , "java.math." } ; private static final Localizer _loc = Localizer . forPackage ( CFMetaDataParser . class ) ; private String _package = null ; private String _class = null ; public CFMetaDataParser ( ) { } protected boolean isPackageElementName ( String name ) { } protected String getPackageAttributeName ( ) { } protected int getPackageElementDepth ( ) { } protected boolean isClassElementName ( String name ) { } protected String getClassAttributeName ( ) { } protected int getClassElementDepth ( ) { } protected boolean startElement ( String name , Attributes attrs ) throws SAXException { } protected void endElement ( String name ) throws SAXException { } protected boolean startPackage ( String elem , Attributes attrs ) throws SAXException { } protected void endPackage ( String elem ) { } protected boolean startClass ( String elem , Attributes attrs ) throws SAXException { } protected void endClass ( String elem ) throws SAXException { } protected boolean startSystemElement ( String name , Attributes attrs ) throws SAXException { } protected void endSystemElement ( String name ) throws SAXException { } protected boolean startPackageElement ( String name , Attributes attrs ) throws SAXException { } protected void endPackageElement ( String name ) throws SAXException { } protected boolean startClassElement ( String name , Attributes attrs ) throws SAXException { } protected void endClassElement ( String name ) throws SAXException { } protected void reset ( ) { } protected String currentClassName ( ) { } protected String currentPackage ( ) { } protected Class classForName ( String name , boolean resolve ) throws SAXException { if ( name == null ) return null ; Class cls = CFMetaDataParser . classForName ( name , _package , resolve , currentClassLoader ( ) ) ; if ( cls == null ) <START_BUG> throw getException ( CFMetaDataParser . _loc . get ( "invalid-class" , name ) ) ; <END_BUG> return cls ; } public static Class classForName ( String name , String pkg , boolean resolve , ClassLoader loader ) { } }

Fix:
throw getException ( CFMetaDataParser . _loc . get ( "invalid-class" , name ) . getMessage ( ) ) ;
Buggy code:
public class StormTabbedFragment extends Fragment { @ Getter protected StormPageAdapter pageAdapter ; protected ViewPager viewPager ; protected PagerSlidingTabStrip indicator ; @ Override public View onCreateView ( LayoutInflater inflater , ViewGroup container , Bundle savedInstanceState ) { } @ Override public void onActivityCreated ( Bundle savedInstanceState ) { } protected void loadPages ( @ NonNull TabbedPageCollection collection ) { <START_BUG> pageAdapter = new StormPageAdapter ( getActivity ( ) , getFragmentManager ( ) ) ; <END_BUG> ArrayList < FragmentPackage > fragmentPages = new ArrayList < FragmentPackage > ( ) ; if ( ( collection . getPages ( ) ) != null ) { for ( TabbedPageDescriptor tabbedPageDescriptor : collection . getPages ( ) ) { FragmentIntent fragmentIntent = UiSettings . getInstance ( ) . getIntentFactory ( ) . getFragmentIntentForPageDescriptor ( tabbedPageDescriptor ) ; if ( fragmentIntent != null ) { FragmentPackage fragmentPackage = new FragmentPackage ( fragmentIntent , tabbedPageDescriptor ) ; fragmentPages . add ( fragmentPackage ) ; } } } pageAdapter . setPages ( fragmentPages ) ; viewPager . setAdapter ( pageAdapter ) ; indicator . setViewPager ( viewPager ) ; } }

Fix:
pageAdapter = new StormPageAdapter ( getActivity ( ) , getChildFragmentManager ( ) ) ;
Buggy code:
public class SizeAssertionGui extends AbstractAssertionGui implements ActionListener , FocusListener { private static final long serialVersionUID = 240L ; private JTextField size ; private JRadioButton equalButton ; private JRadioButton notequalButton ; private JRadioButton greaterthanButton ; private JRadioButton lessthanButton ; private JRadioButton greaterthanequalButton ; private JRadioButton lessthanequalButton ; private int execState ; public SizeAssertionGui ( ) { } public String getLabelResource ( ) { } public TestElement createTestElement ( ) { } public void modifyTestElement ( TestElement el ) { } @ Override public void clearGui ( ) { } @ Override public void configure ( TestElement el ) { } public void setState ( int state ) { } public int getState ( ) { } private void init ( ) { setLayout ( new VerticalLayout ( 5 , VerticalLayout . BOTH , VerticalLayout . TOP ) ) ; setBorder ( makeBorder ( ) ) ; add ( makeTitlePanel ( ) ) ; <START_BUG> add ( createScopePanel ( ) ) ; <END_BUG> JPanel sizePanel = new JPanel ( ) ; sizePanel . setBorder ( BorderFactory . createTitledBorder ( BorderFactory . createEtchedBorder ( ) , JMeterUtils . getResString ( "size_assertion_size_test" ) ) ) ; sizePanel . add ( new JLabel ( JMeterUtils . getResString ( "size_assertion_label" ) ) ) ; size = new JTextField ( 5 ) ; size . addFocusListener ( this ) ; sizePanel . add ( size ) ; sizePanel . add ( createComparatorButtonPanel ( ) ) ; add ( sizePanel ) ; } private Box createComparatorButtonPanel ( ) { } private JRadioButton createComparatorButton ( String name , int value , ButtonGroup group ) { } public void focusLost ( FocusEvent e ) { } public void focusGained ( FocusEvent e ) { } public void actionPerformed ( ActionEvent e ) { } }

Fix:
add ( createScopePanel ( true ) ) ;
Buggy code:
public class ResourceManager implements Runnable { private GridModel model ; private boolean interruptFlag = false ; private ReentrantLock lock = new ReentrantLock ( ) ; public ResourceManager ( GridModel model ) { } public void run ( ) { boolean interrupt = false ; while ( ! interrupt ) { model . updateSquares ( ) ; try { <START_BUG> Thread . sleep ( 1000 ) ; <END_BUG> } catch ( InterruptedException e ) { e . printStackTrace ( ) ; } lock . lock ( ) ; interrupt = interruptFlag ; lock . unlock ( ) ; } } public void stop ( ) { } }

Fix:
Thread . sleep ( 3000 ) ;
Buggy code:
public class StandardJMeterEngine implements Serializable , Runnable , JMeterEngine , JMeterThreadMonitor { private static transient Logger log = LoggingManager . getLoggerForClass ( ) ; private transient Thread runningThread ; private static long WAIT_TO_DIE = 5 * 1000 ; transient Map allThreads ; boolean running = false ; boolean serialized = false ; boolean schcdule_run = false ; HashTree test ; transient SearchByClass testListeners ; String host = null ; transient ListenerNotifier notifier ; public StandardJMeterEngine ( ) { } public StandardJMeterEngine ( String host ) { } public void configure ( HashTree testTree ) { } public void setHost ( String host ) { } protected HashTree getTestTree ( ) { } protected void compileTree ( ) { } public void runTest ( ) throws JMeterEngineException { } private void removeThreadGroups ( List elements ) { } protected void setMode ( ) { } protected void notifyTestListenersOfStart ( ) { } protected void notifyTestListenersOfEnd ( ) { } private ListedHashTree cloneTree ( ListedHashTree tree ) { } public void reset ( ) { } public synchronized void threadFinished ( JMeterThread thread ) { } public synchronized void stopTest ( ) { } private class StopTest implements Runnable { public void run ( ) { } } public void run ( ) { } private void scheduleThread ( JMeterThread thread , ThreadGroup group ) { } public synchronized void pauseTest ( int milis ) { Iterator iter = new HashSet ( allThreads . keySet ( ) ) . iterator ( ) ; while ( iter . hasNext ( ) ) { Thread t = ( ( Thread ) ( allThreads . get ( iter . next ( ) ) ) ) ; if ( ( t != null ) && ( t . isAlive ( ) ) ) { try { <START_BUG> t . sleep ( milis ) ; <END_BUG> } catch ( InterruptedException e ) { } } } } private void verifyThreadsStopped ( ) { } private void tellThreadsToStop ( ) { } public void askThreadsToStop ( ) { } public void exit ( ) { } }

Fix:
Thread . sleep ( milis ) ;
Buggy code:
public final class DefaultTabList extends SimpleTabList implements Listener { private Map < Player , String > names = new HashMap < > ( ) ; private int taskId ; public DefaultTabList ( Tabbed tabbed , Player player , int maxItems ) { } @ Override @ Deprecated public void add ( TabItem item ) { } @ Override @ Deprecated public void add ( int index , TabItem item ) { } @ Override @ Deprecated public TabItem set ( int index , TabItem item ) { } @ Override @ Deprecated <START_BUG> public void remove ( int index ) { <END_BUG> throw new UnsupportedOperationException ( ) ; } @ Override public DefaultTabList enable ( ) { } @ Override public DefaultTabList disable ( ) { } @ EventHandler public void onPlayerJoin ( PlayerJoinEvent event ) { } @ EventHandler public void onPlayerJoin ( PlayerQuitEvent event ) { } private void addPlayer ( Player player ) { } private int getTabItemIndex ( Player player ) { } private int getInsertLocation ( Player player ) { } }

Fix:
public TabItem remove ( int index ) {
Buggy code:
public class DictionaryController extends Controller { public void create ( ) { } public void modify ( ) { <START_BUG> int id = getParaToInt ( "id" ) ; <END_BUG> DictionaryKind dictionaryKind = dao . findById ( id ) ; setAttr ( "dictionarykind" , dictionaryKind ) ; render ( "create.html" ) ; } @ Before ( DictionaryKindFormValidator . class ) public void save ( ) { } public void view ( ) { } @ Before ( Tx . class ) public void delete ( ) { } public void list ( ) { } public void add ( ) { } @ Before ( DictionaryFormValidator . class ) public void saveDict ( ) { } public void remove ( ) { } public void all ( ) { } }

Fix:
int id = getParaToInt ( 0 ) ;
Buggy code:
public final class FrenchStemFilter extends TokenFilter { private Token token = null ; private FrenchStemmer stemmer = null ; private Set exclusions = null ; public FrenchStemFilter ( TokenStream in ) { } public FrenchStemFilter ( TokenStream in , Hashtable exclusiontable ) { } public FrenchStemFilter ( TokenStream in , Set exclusiontable ) { } public final Token next ( ) throws IOException { if ( ( token = input . next ( ) ) == null ) { return null ; } else if ( ( ( exclusions ) != null ) && ( exclusions . contains ( token . termText ( ) ) ) ) { return token ; } else { String s = stemmer . stem ( token . termText ( ) ) ; if ( ! ( s . equals ( token . termText ( ) ) ) ) { <START_BUG> return new Token ( s , 0 , s . length ( ) , token . type ( ) ) ; <END_BUG> } return token ; } } public void setStemmer ( FrenchStemmer stemmer ) { } public void setExclusionTable ( Hashtable exclusiontable ) { } }

Fix:
return new Token ( s , token . startOffset ( ) , token . endOffset ( ) , token . type ( ) ) ;
Buggy code:
public class ClimbingEvent { private String id ; private String owner_name ; private String owner_id ; private LatLng from ; private LatLng to ; private int from_radius ; private int to_radius ; private GregorianCalendar from_date ; private GregorianCalendar to_date ; private int from_delta ; private int to_delta ; private String type ; private String lower_grade ; private String upper_grade ; private boolean indoor ; private boolean equips ; private Date publish_date ; private boolean publish ; private int status ; private ArrayList < String > climbers ; public LatLng getPosition ( ) { } public void setClimbers ( String cs ) { } public ArrayList < String > getClimbers ( ) { } public ClimbingEvent ( ) { } public boolean equals ( ClimbingEvent other ) { <START_BUG> return ( id ) == ( other . getId ( ) ) ; <END_BUG> } public ClimbingEvent ( double lat , double lng ) { } public ClimbingEvent ( ClimbingEvent old ) { } public ClimbingEvent ( JSONObject jobj ) { } private void default_init ( ) { } public void addClimber ( String id ) { } public void removeOwner ( ) { } public void removeClimber ( String id ) { } public JSONObject toJSON ( ) { } public String getFromDateView ( ) { } public String getToDateView ( ) { } public int getFromDelta ( ) { } public void setFromDelta ( int from_delta ) { } public String getOwnerId ( ) { } public void setOwnerId ( String owner ) { } public String getOwnerName ( ) { } public void setOwnerName ( String owner ) { } public LatLng getFrom ( ) { } public void setFrom ( double lat , double lng ) { } public LatLng getTo ( ) { } public void setTo ( double lat , double lng ) { } public int getFromRadius ( ) { } public void setFromRadius ( int from_radius ) { } public int getToRadius ( ) { } public void setToRadius ( int to_radius ) { } public GregorianCalendar getFromDate ( ) { } public void setFromDate ( Date from_date ) { } public void setFromDate ( GregorianCalendar from_date ) { } public void setFromDate ( int day , int month , int year ) { } public GregorianCalendar getToDate ( ) { } public void setToDate ( Date to_date ) { } public void setToDate ( GregorianCalendar to_date ) { } public void setToDate ( int day , int month , int year ) { } public int getToDelta ( ) { } public void setToDelta ( int to_delta ) { } public String getType ( ) { } public void setType ( String type ) { } public String getLowerGrade ( ) { } public void setLowerGrade ( String lower_grade ) { } public String getUpperGrade ( ) { } public void setUpperGrade ( String upper_grade ) { } public boolean isIndoor ( ) { } public void setIndoor ( boolean indoor ) { } public boolean isEquips ( ) { } public void setEquips ( boolean equips ) { } public Date getPublishDate ( ) { } public void setPublishDate ( Date publish_date ) { } public boolean isPublish ( ) { } public void setPublish ( boolean publish ) { } public String getId ( ) { } public void setId ( String id ) { } public int getStatus ( ) { } public void setStatus ( int st ) { } No newline ; at end ; of file ; }

Fix:
return id . equals ( other . getId ( ) ) ;
Buggy code:
public class HttpTestSampleGui extends AbstractSamplerGui { private UrlConfigGui urlConfigGui ; private JCheckBox getImages ; public HttpTestSampleGui ( ) { } public void configure ( TestElement element ) { super . configure ( element ) ; urlConfigGui . configure ( element ) ; <START_BUG> String testClass = ( ( String ) ( element . getProperty ( TEST_CLASS ) ) ) ; <END_BUG> if ( ( testClass != null ) && ( testClass . endsWith ( "Full" ) ) ) { getImages . setSelected ( true ) ; } else { getImages . setSelected ( false ) ; } } public TestElement createTestElement ( ) { } public void modifyTestElement ( TestElement sampler ) { } public String getStaticLabel ( ) { } private void init ( ) { } private JPanel createOptionalTasksPanel ( ) { } }

Fix:
String testClass = element . getPropertyAsString ( TEST_CLASS ) ;
Buggy code:
public class InvalidLDAPServerAuthenticationTest extends BaseJDBCTestCase { public InvalidLDAPServerAuthenticationTest ( String name ) { } protected void initializeConnection ( Connection conn ) throws SQLException { } public static Test suite ( ) { } public static Test baseSuite ( String name ) { } protected void setDatabaseProperty ( String propertyName , String value , Connection conn ) throws SQLException { } public void testInvalidLDAPServerConnectionError ( ) throws SQLException { Connection conn = getConnection ( ) ; setDatabaseProperty ( "derby.connection.requireAuthentication" , "true" , conn ) ; setDatabaseProperty ( "derby.authentication.provider" , "LDAP" , conn ) ; <START_BUG> setDatabaseProperty ( "derby.authentication.server" , "noSuchServer" , conn ) ; <END_BUG> setDatabaseProperty ( "derby.authentication.ldap.searchBase" , "o=dnString" , conn ) ; setDatabaseProperty ( "derby.authentication.ldap.searchFilter" , "(&(objectClass=inetOrgPerson)(uid=%USERNAME%))" , conn ) ; commit ( ) ; conn . setAutoCommit ( true ) ; conn . close ( ) ; TestConfiguration . getCurrent ( ) . shutdownDatabase ( ) ; String dbName = TestConfiguration . getCurrent ( ) . getDefaultDatabaseName ( ) ; DataSource ds = JDBCDataSource . getDataSource ( dbName ) ; try { ds . getConnection ( ) ; fail ( "expected<seq2seq4repair_space>java.net.UnknownHostException<seq2seq4repair_space>for<seq2seq4repair_space>datasource" ) ; } catch ( SQLException se ) { assertSQLState ( "08004" , se ) ; if ( usingEmbedded ( ) ) assertTrue ( ( ( se . getMessage ( ) . indexOf ( "java.net.UnknownHostException" ) ) > 1 ) ) ; } String url2 = TestConfiguration . getCurrent ( ) . getJDBCUrl ( dbName ) ; try { DriverManager . getConnection ( url2 , "user" , "password" ) . close ( ) ; fail ( "expected<seq2seq4repair_space>java.net.UnknownHostException<seq2seq4repair_space>for<seq2seq4repair_space>driver" ) ; } catch ( SQLException se ) { assertSQLState ( "08004" , se ) ; if ( usingEmbedded ( ) ) assertTrue ( ( ( se . getMessage ( ) . indexOf ( "java.net.UnknownHostException" ) ) > 1 ) ) ; } shutdownSystem ( ) ; } protected void shutdownSystem ( ) throws SQLException { } }

Fix:
setDatabaseProperty ( "derby.authentication.server" , "noSuchServer.invalid" , conn ) ;
Buggy code:
public class CompilationUnitScope extends Scope { public LookupEnvironment environment ; public CompilationUnitDeclaration referenceContext ; public char [ ] [ ] currentPackageName ; public PackageBinding fPackage ; public ImportBinding [ ] imports ; public HashtableOfObject typeOrPackageCache ; public SourceTypeBinding [ ] topLevelTypes ; private CompoundNameVector qualifiedReferences ; private SimpleNameVector simpleNameReferences ; private ObjectVector referencedTypes ; private ObjectVector referencedSuperTypes ; HashtableOfType constantPoolNameUsage ; public CompilationUnitScope ( CompilationUnitDeclaration unit , LookupEnvironment environment ) { } void buildFieldsAndMethods ( ) { } void buildTypeBindings ( AccessRestriction accessRestriction ) { } void checkAndSetImports ( ) { } void checkParameterizedTypeBounds ( ) { } public char [ ] computeConstantPoolName ( LocalTypeBinding localType ) { } void connectTypeHierarchy ( ) { } void faultInImports ( ) { } public void faultInTypes ( ) { } private Binding findImport ( char [ ] [ ] compoundName , int length ) { } private Binding findSingleImport ( char [ ] [ ] compoundName , boolean findStaticImports ) { } private Binding findSingleStaticImport ( char [ ] [ ] compoundName ) { } MethodBinding findStaticMethod ( ReferenceBinding currentType , char [ ] selector ) { if ( ! ( currentType . canBeSeenBy ( this ) ) ) return null ; do { MethodBinding [ ] methods = currentType . getMethods ( selector ) ; <START_BUG> if ( methods != ( NoMethods ) ) { <END_BUG> for ( int i = methods . length ; ( -- i ) >= 0 ; ) { MethodBinding method = methods [ i ] ; if ( ( method . isStatic ( ) ) && ( method . canBeSeenBy ( fPackage ) ) ) return method ; } } if ( ( currentType . superInterfaces ( ) ) == null ) ( ( SourceTypeBinding ) ( currentType ) ) . scope . connectTypeHierarchy ( ) ; } while ( ( currentType = currentType . superclass ( ) ) != null ) ; return null ; } ImportBinding [ ] getDefaultImports ( ) { } public final Binding getImport ( char [ ] [ ] compoundName , boolean onDemand , boolean isStaticImport ) { } public ProblemReporter problemReporter ( ) { } void recordQualifiedReference ( char [ ] [ ] qualifiedName ) { } void recordReference ( char [ ] [ ] qualifiedEnclosingName , char [ ] simpleName ) { } void recordReference ( ReferenceBinding type , char [ ] simpleName ) { } void recordSimpleReference ( char [ ] simpleName ) { } void recordSuperTypeReference ( TypeBinding type ) { } public void recordTypeConversion ( TypeBinding superType , TypeBinding subType ) { } void recordTypeReference ( TypeBinding type ) { } void recordTypeReferences ( TypeBinding [ ] types ) { } Binding resolveSingleImport ( ImportBinding importBinding ) { } public void storeDependencyInfo ( ) { } public String toString ( ) { } private ReferenceBinding typeToRecord ( TypeBinding type ) { } public void verifyMethods ( MethodVerifier verifier ) { } }

Fix:
if ( methods != ( Binding . NO_METHODS ) ) {
Buggy code:
public class ReleaseLoader extends PersistingAsyncTaskLoader < AsyncEntityResult < Release > > { private Credentials creds ; private String userAgent ; private String mbid ; public ReleaseLoader ( Context context , Credentials creds , String mbid ) { } public ReleaseLoader ( Context context , String userAgent , String mbid ) { } @ Override public AsyncEntityResult < Release > loadInBackground ( ) { } private AsyncEntityResult < Release > getAvailableData ( ) throws IOException { } private AsyncEntityResult < Release > getRelease ( ) throws IOException { } private AsyncEntityResult < Release > getReleaseWithUserData ( ) throws IOException { MusicBrainz client = new org . musicbrainz . android . api . webservice . WebClient ( creds ) ; Release release = client . lookupRelease ( mbid ) ; <START_BUG> UserData userData = client . lookupUserData ( RELEASE_GROUP , mbid ) ; <END_BUG> data = new AsyncEntityResult < Release > ( LoaderStatus . SUCCESS , release , userData ) ; return data ; } }

Fix:
UserData userData = client . lookupUserData ( RELEASE_GROUP , release . getReleaseGroupMbid ( ) ) ;
Buggy code:
public abstract class AjaxFormSubmitBehavior extends AjaxEventBehavior { private static final long serialVersionUID = 1L ; private Form form ; public AjaxFormSubmitBehavior ( Form form , String event ) { } protected String getEventHandler ( ) { final String formId = form . getMarkupId ( ) ; final String url = getCallbackUrl ( ) ; <START_BUG> return ( getCallbackScript ( ( ( ( ( "wicketSubmitFormById('" + formId ) + "',<seq2seq4repair_space>'" ) + url ) + "'<seq2seq4repair_space>" ) , null , null ) ) + ";<seq2seq4repair_space>return<seq2seq4repair_space>true;" ; <END_BUG> } protected void onEvent ( AjaxRequestTarget target ) { } protected abstract void onSubmit ( AjaxRequestTarget target ) { } }

Fix:
return ( getCallbackScript ( ( ( ( ( "wicketSubmitFormById('" + formId ) + "',<seq2seq4repair_space>'" ) + url ) + "'<seq2seq4repair_space>" ) , null , null ) ) + ";" ;
Buggy code:
public class TestSolrProperties { protected static Logger log = Logger . getLogger ( TestSolrProperties . class . getName ( ) ) ; protected CoreContainer cores = null ; public String getSolrHome ( ) { } public String getSolrXml ( ) { } @ Before public void setUp ( ) throws Exception { } @ After public void tearDown ( ) throws Exception { if ( ( cores ) != null ) cores . shutdown ( ) ; File dataDir = new File ( ( ( getSolrHome ( ) ) + "//data" ) ) ; String skip = System . getProperty ( "solr.test.leavedatadir" ) ; if ( ( null != skip ) && ( 0 != ( skip . trim ( ) . length ( ) ) ) ) { TestSolrProperties . log . info ( ( "NOTE:<seq2seq4repair_space>per<seq2seq4repair_space>solr.test.leavedatadir,<seq2seq4repair_space>dataDir<seq2seq4repair_space>will<seq2seq4repair_space>not<seq2seq4repair_space>be<seq2seq4repair_space>removed:<seq2seq4repair_space>" + ( dataDir . getAbsolutePath ( ) ) ) ) ; } else { if ( ! ( AbstractSolrTestCase . recurseDelete ( dataDir ) ) ) { TestSolrProperties . log . warning ( ( ( "!!!!<seq2seq4repair_space>WARNING:<seq2seq4repair_space>best<seq2seq4repair_space>effort<seq2seq4repair_space>to<seq2seq4repair_space>remove<seq2seq4repair_space>" + ( dataDir . getAbsolutePath ( ) ) ) + "<seq2seq4repair_space>FAILED<seq2seq4repair_space>!!!!!" ) ) ; } } <START_BUG> File persistedFile = new File ( "solr-persist.xml" ) ; <END_BUG> persistedFile . delete ( ) ; } protected SolrServer getSolrCore0 ( ) { } protected SolrServer getSolrCore1 ( ) { } protected SolrServer getSolrAdmin ( ) { } protected SolrServer getSolrCore ( String name ) { } @ Test public void testProperties ( ) throws Exception { } }

Fix:
File persistedFile = new File ( ( ( ( getSolrHome ( ) ) + ( File . separator ) ) + "solr-persist.xml" ) ) ;
Buggy code:
public class ShowCheckForUpdateCommand extends CommandBase implements ICommand { public static final String NAME = "Check<seq2seq4repair_space>For<seq2seq4repair_space>Updates..." ; public String getName ( ) { } public String getDescription ( ) { } public ImageIcon getIcon ( ) { } public KeyStroke getAcceleratorKey ( ) { } @ Override public void apply ( NexusStreamParser np ) throws Exception { } public void actionPerformed ( ActionEvent ev ) { ApplicationDisplayMode applicationDisplayMode = ( ProgramProperties . isUseGUI ( ) ) ? ApplicationDisplayMode . GUI : ApplicationDisplayMode . CONSOLE ; UpdateDescriptor updateDescriptor ; try { updateDescriptor = UpdateChecker . getUpdateDescriptor ( "http:////www-ab.informatik.uni-tuebingen.de//data//software//dendroscope//download//updates.xml" , applicationDisplayMode ) ; } catch ( Exception e ) { Basic . caught ( e ) ; new jloda . util . Alert ( MultiViewer . getLastActiveFrame ( ) , "Installed<seq2seq4repair_space>version<seq2seq4repair_space>is<seq2seq4repair_space>up-to-date" ) ; return ; } if ( ( updateDescriptor . getEntries ( ) . length ) > 0 ) { if ( ! ( ProgramProperties . isUseGUI ( ) ) ) { UpdateDescriptorEntry entry = updateDescriptor . getEntries ( ) [ 0 ] ; new jloda . util . Alert ( MultiViewer . getLastActiveFrame ( ) , ( ( "New<seq2seq4repair_space>version<seq2seq4repair_space>available:<seq2seq4repair_space>" + ( entry . getNewVersion ( ) ) ) + "\nPlease<seq2seq4repair_space>download<seq2seq4repair_space>from:<seq2seq4repair_space>http:////www-ab.informatik.uni-tuebingen.de//data//software//dendroscope//download//" ) ) ; return ; } } else { new jloda . util . Alert ( MultiViewer . getLastActiveFrame ( ) , "Installed<seq2seq4repair_space>version<seq2seq4repair_space>is<seq2seq4repair_space>up-to-date" ) ; return ; } <START_BUG> ApplicationLauncher . launchApplicationInProcess ( "1691242905" , null , new ApplicationLauncher . Callback ( ) { <END_BUG> public void exited ( int exitValue ) { } public void prepareShutdown ( ) { ProgramProperties . store ( ) ; } } , FRAME , null ) ; } public boolean isCritical ( ) { } public boolean isApplicable ( ) { } @ Override public String getSyntax ( ) { } public String getUndo ( ) { } }

Fix:
ApplicationLauncher . launchApplicationInProcess ( "1691242142" , null , new ApplicationLauncher . Callback ( ) {
Buggy code:
public class AttachmentDataRule extends BaseRule { public AttachmentDataRule ( ImportBean ib ) { } public void body ( String text ) throws Exception { log ( ) . debug ( ( ( ( "(" + ( getImportBean ( ) . getState ( ) ) ) + ")<seq2seq4repair_space>attachment<seq2seq4repair_space>data<seq2seq4repair_space>body:<seq2seq4repair_space>" ) + text ) ) ; Attachment attachment = getImportBean ( ) . getAttachment ( ) ; <START_BUG> attachment . setDataAsString ( text ) ; <END_BUG> } }

Fix:
attachment . setData ( text ) ;