nus-yam/ex-repair huggingface dataset:
Buggy code:
public abstract class RefreshingView extends RepeatingView { private static final long serialVersionUID = 1L ; private IItemReuseStrategy itemReuseStrategy ; public RefreshingView ( MarkupContainer parent , final String id ) { } public RefreshingView ( MarkupContainer parent , final String id , IModel model ) { } @ Override protected void internalOnAttach ( ) { } protected abstract Iterator getItemModels ( ) { } protected abstract void populateItem ( final Item item ) { } protected Item newItem ( final String id , int index , final IModel model ) { } public Iterator getItems ( ) { } protected void addItems ( Iterator items ) { while ( items . hasNext ( ) ) { <START_BUG> ( ( Item ) ( items . next ( ) ) ) . reattach ( ) ; <END_BUG> } } public IItemReuseStrategy getItemReuseStrategy ( ) { } public RefreshingView setItemReuseStrategy ( IItemReuseStrategy strategy ) { } }

Fix:
( ( Item ) ( items . next ( ) ) ) . reAttach ( ) ;
Buggy code:
@ ExposableOptions ( strategy = ConfigStrategy . Versioned , filename = "staffderpsmod.json" ) public class LiteModItemSorter implements ChatFilter , OutboundChatListener , Tickable { private ChestSorter chestSorter ; private ConfigFile configFile ; private boolean sentCmd ; private int grabCooldown ; public LiteModItemSorter ( ) { } @ Override public String getName ( ) { } @ Override public String getVersion ( ) { <START_BUG> return "1.0.0" ; <END_BUG> } @ Override public void init ( File configPath ) { } @ Override public void upgradeSettings ( String version , File configPath , File oldConfigPath ) { } @ Override public void onTick ( Minecraft minecraft , float partialTicks , boolean inGame , boolean clock ) { } @ Override public void onSendChatMessage ( C01PacketChatMessage packet , String message ) { } @ Override public boolean onChat ( S02PacketChat chatPacket , IChatComponent chat , String message ) { } public static void logMessage ( String message , boolean addPrefix ) { } public static void logError ( String message ) { } }

Fix:
return "1.0.1" ;
Buggy code:
public final class CharId extends OpenJPAId { private final char key ; public CharId ( Class cls , Character key ) { } public CharId ( Class cls , String key ) { } public CharId ( Class cls , char key ) { } public CharId ( Class cls , char key , boolean subs ) { } public char getId ( ) { } public Object getIdObject ( ) { <START_BUG> return new Character ( key ) ; <END_BUG> } public String toString ( ) { } protected int idHash ( ) { } protected boolean idEquals ( OpenJPAId o ) { } }

Fix:
return Character . valueOf ( key ) ;
Buggy code:
@ Service public class PlanningServiceImpl implements PlanningService { @ Autowired private PlanningDAO planningDAO ; @ Autowired private ParticipantDAO participantDAO ; @ Autowired private PriorityDAO priorityDAO ; @ Autowired private PersonMailResolver personResolver ; @ Autowired private PersonDAO personDAO ; @ Autowired private UnavailabilityDAO unavailabilityDAO ; public List < Planning > findAll ( ) { } public Planning findById ( Integer id ) { } public Planning create ( Person admin , String name , TimeBox period , Integer oralDefenseDuration , Integer oralDefenseInterlude , TimeBox lunchBreak , TimeBox dayPeriod , Integer nbMaxOralDefensePerDay , Collection < Room > rooms ) { } public void update ( Planning planning , String name , TimeBox period , Integer oralDefenseDuration , Integer oralDefenseInterlude , TimeBox lunchBreak , TimeBox dayPeriod , Integer nbMaxOralDefensePerDay , Collection < Room > rooms ) { Validate . notNull ( planning ) ; if ( ( name != null ) && ( ! ( name . equals ( "" ) ) ) ) { planning . setName ( name ) ; } if ( period != null ) { period . validate ( ) ; planning . setPeriod ( period ) ; } if ( ( oralDefenseDuration != null ) && ( oralDefenseDuration > 0 ) ) { planning . setOralDefenseDuration ( oralDefenseDuration ) ; } if ( dayPeriod != null ) { dayPeriod . validate ( ) ; <START_BUG> planning . setDayPeriod ( period ) ; <END_BUG> } if ( lunchBreak != null ) { lunchBreak . validate ( ) ; planning . setLunchBreak ( lunchBreak ) ; } planning . setOralDefenseInterlude ( oralDefenseInterlude ) ; planning . setNbMaxOralDefensePerDay ( nbMaxOralDefensePerDay ) ; if ( rooms != null ) { planning . setRooms ( rooms ) ; } planningDAO . update ( planning ) ; } public List < Planning > findAllByUid ( String uid ) { } public Planning importPartcipants ( Planning planning , File file ) throws Exception { } public Collection < Participant > findParticipants ( Planning planning ) { } @ Override public Collection < Priority > findPriorities ( Planning planning ) { } @ Override public Collection < Priority > updatePriorities ( Planning planning , Collection < Priority > priorities ) { } @ Override public File exportExcel ( Integer planningId ) { } @ Override public Collection < OralDefense > export ( Integer planningId ) { } @ Override public void validate ( Integer planningId ) { } }

Fix:
planning . setDayPeriod ( dayPeriod ) ;
Buggy code:
public class InitializeClassTest extends BuildFileTest { public InitializeClassTest ( String name ) { } public void setUp ( ) { } public void testAll ( ) throws IOException { executeTarget ( "forked" ) ; PrintStream ps = System . out ; File f1 = new File ( "src//etc//testcases//taskdefs//forkedout" ) ; File f2 = new File ( "src//etc//testcases//taskdefs//unforkedout" ) ; PrintStream newps = new PrintStream ( new FileOutputStream ( f2 ) ) ; System . setOut ( newps ) ; project . executeTarget ( "unforked" ) ; System . setOut ( ps ) ; newps . close ( ) ; FileUtils fu = FileUtils . newFileUtils ( ) ; <START_BUG> assertTrue ( fu . contentEquals ( f1 , f2 ) ) ; <END_BUG> } public void tearDown ( ) { } }

Fix:
assertTrue ( "Forked<seq2seq4repair_space>-<seq2seq4repair_space>non-forked<seq2seq4repair_space>mismatch" , fu . contentEquals ( f1 , f2 ) ) ;
Buggy code:
class NewServerInventoryService implements Service < NewServerInventory > { private static final Logger log = Logger . getLogger ( "org.jboss.as.host.controller" ) ; static final ServiceName SERVICE_NAME = JBOSS . append ( "host" , "controller" , "server-inventory" ) ; private final InjectedValue < NewProcessControllerConnectionService > client = new InjectedValue < NewProcessControllerConnectionService > ( ) ; private final NetworkInterfaceBinding interfaceBinding ; private final NewDomainController domainController ; private final HostControllerEnvironment environment ; private final int port ; private final NewServerInventoryService . FutureServerInventory futureInventory = new NewServerInventoryService . FutureServerInventory ( ) ; private NewServerInventory serverInventory ; private NewServerInventoryService ( final NewDomainController domainController , final HostControllerEnvironment environment , final NetworkInterfaceBinding interfaceBinding , final int port ) { } static Future < NewServerInventory > install ( final ServiceTarget serviceTarget , final NewDomainController domainController , final HostControllerEnvironment environment , final NetworkInterfaceBinding interfaceBinding , final int port ) { final NewServerInventoryService inventory = new NewServerInventoryService ( domainController , environment , interfaceBinding , port ) ; <START_BUG> serviceTarget . addService ( ServerInventoryService . SERVICE_NAME , inventory ) . addDependency ( NewProcessControllerConnectionService . SERVICE_NAME , NewProcessControllerConnectionService . class , inventory . getClient ( ) ) . install ( ) ; <END_BUG> return inventory . futureInventory ; } @ Override public synchronized void start ( StartContext context ) throws StartException { } public Future < NewServerInventory > getInventoryFuture ( ) { } @ Override public synchronized void stop ( StopContext context ) { } @ Override public synchronized NewServerInventory getValue ( ) throws IllegalArgumentException , IllegalStateException { } InjectedValue < NewProcessControllerConnectionService > getClient ( ) { } private class FutureServerInventory extends AsyncFutureTask < NewServerInventory > { protected FutureServerInventory ( ) { } private void setInventory ( NewServerInventory inventory ) { } } }

Fix:
serviceTarget . addService ( NewServerInventoryService . SERVICE_NAME , inventory ) . addDependency ( NewProcessControllerConnectionService . SERVICE_NAME , NewProcessControllerConnectionService . class , inventory . getClient ( ) ) . install ( ) ;
Buggy code:
public class MainActivity extends ActionBarActivity implements AuthManager . AuthCallback { private static final String TAG = MainActivity . class . getSimpleName ( ) ; private Firebase mFirebase ; private ChildEventListener mTransactionListener ; private DrawerLayout mDrawerLayout ; private ListView mListView ; private ListView mDrawerNavigation ; private ArrayAdapter < CharSequence > mSpinnerAdapter ; private String mTransactionFilter ; private String mRoomId ; private ArrayList < Transaction > mTransactions ; @ Override protected void onCreate ( Bundle savedInstanceState ) { } @ Override protected void onStart ( ) { } @ Override protected void onResume ( ) { } @ Override protected void onPause ( ) { } @ Override protected void onStop ( ) { } @ Override protected void onDestroy ( ) { } @ Override public void onActivityResult ( int requestCode , int resultCode , Intent data ) { <START_BUG> AuthManager . getInstance ( this ) . onActivityResult ( requestCode , resultCode , data ) ; <END_BUG> } @ Override public void onAuthResult ( Auth auth , Error error ) { } private void createToolbar ( ) { } private void createTransactionFilter ( ) { } private void createTransactionViews ( ) { } private void createDrawer ( ) { } private void createFirebase ( ) { } private void updateTransactionFilter ( ) { } private void updateTransactionsUi ( ) { } private void updateAuthDependentListeners ( ) { } }

Fix:
AuthManager . onActivityResult ( this , requestCode , resultCode , data ) ;
Buggy code:
public class MethodRefParameter extends ASTNode { public static final ChildPropertyDescriptor TYPE_PROPERTY = new ChildPropertyDescriptor ( MethodRefParameter . class , "type" , Type . class , ASTNode . MANDATORY , ASTNode . NO_CYCLE_RISK ) ; public static final SimplePropertyDescriptor VARARGS_PROPERTY = new SimplePropertyDescriptor ( MethodRefParameter . class , "varargs" , boolean . class , ASTNode . MANDATORY ) ; public static final ChildPropertyDescriptor NAME_PROPERTY = new ChildPropertyDescriptor ( MethodRefParameter . class , "name" , SimpleName . class , ASTNode . OPTIONAL , ASTNode . NO_CYCLE_RISK ) ; private static final List PROPERTY_DESCRIPTORS_2_0 ; private static final List PROPERTY_DESCRIPTORS_3_0 ; public static List propertyDescriptors ( int apiLevel ) { } private Type type = null ; private boolean variableArity = false ; private SimpleName optionalParameterName = null ; MethodRefParameter ( AST ast ) { } final List internalStructuralPropertiesForType ( int apiLevel ) { } final ASTNode internalGetSetChildProperty ( ChildPropertyDescriptor property , boolean get , ASTNode child ) { } final boolean internalGetSetBooleanProperty ( SimplePropertyDescriptor property , boolean get , boolean value ) { } final int getNodeType0 ( ) { } ASTNode clone0 ( AST target ) { MethodRefParameter result = new MethodRefParameter ( target ) ; <START_BUG> result . setSourceRange ( this . getStartPosition ( ) , this . getLength ( ) ) ; <END_BUG> result . setType ( ( ( Type ) ( ASTNode . copySubtree ( target , getType ( ) ) ) ) ) ; if ( ( this . ast . apiLevel ) >= ( AST . JLS3 ) ) { result . setVarargs ( isVarargs ( ) ) ; } result . setName ( ( ( SimpleName ) ( ASTNode . copySubtree ( target , getName ( ) ) ) ) ) ; return result ; } final boolean subtreeMatch0 ( ASTMatcher matcher , Object other ) { } void accept0 ( ASTVisitor visitor ) { } public Type getType ( ) { } public void setType ( Type type ) { } public boolean isVarargs ( ) { } public void setVarargs ( boolean variableArity ) { } public SimpleName getName ( ) { } public void setName ( SimpleName name ) { } int memSize ( ) { } int treeSize ( ) { } }

Fix:
result . setSourceRange ( getStartPosition ( ) , getLength ( ) ) ;
Buggy code:
public class SearchActivity extends Activity { ExpandableListView epView ; @ Override public void onCreate ( Bundle savedInstanceState ) { } public class SearchResultsAdapter extends BaseExpandableListAdapter { Context _context ; LayoutInflater _layoutInflater ; String [ ] _groups = getResources ( ) . getStringArray ( search_groups ) ; Vector < Subscription > _subscriptions = new Vector < Subscription > ( ) ; Vector < Podcast > _podcasts = new Vector < Podcast > ( ) ; String _query = "" ; public SearchResultsAdapter ( Context context ) { } public SearchResultsAdapter ( Context context , String query ) { } public Object getChild ( int groupPosition , int childPosition ) { } public long getChildId ( int groupPosition , int childPosition ) { } public View getChildView ( int groupPosition , int childPosition , boolean isLastChild , View convertView , ViewGroup parent ) { } public int getChildrenCount ( int groupPosition ) { } public Object getGroup ( int groupPosition ) { } public int getGroupCount ( ) { } public long getGroupId ( int groupPosition ) { } public View getGroupView ( int groupPosition , boolean isExpanded , View convertView , ViewGroup parent ) { TextView view ; if ( convertView == null ) { view = ( ( TextView ) ( _layoutInflater . inflate ( list_item , null ) ) ) ; } else { view = ( ( TextView ) ( convertView ) ) ; } <START_BUG> view . setPadding ( ( ( view . getPaddingLeft ( ) ) + 25 ) , view . getPaddingTop ( ) , view . getPaddingRight ( ) , view . getPaddingBottom ( ) ) ; <END_BUG> view . setText ( _groups [ groupPosition ] ) ; return view ; } public boolean hasStableIds ( ) { } public boolean isChildSelectable ( int groupPosition , int childPosition ) { } } No newline ; at end ; of file ; }

Fix:
view . setPadding ( 60 , 0 , 0 , 0 ) ;
Buggy code:
public class TestOrdValues extends FunctionTestSetup { public TestOrdValues ( ) { } @ Test public void testOrdFieldRank ( ) throws Exception , CorruptIndexException { } @ Test public void testReverseOrdFieldRank ( ) throws Exception , CorruptIndexException { } private void doTestRank ( String field , boolean inOrder ) throws Exception , CorruptIndexException { IndexSearcher s = new IndexSearcher ( dir , true ) ; ValueSource vs ; if ( inOrder ) { vs = new MultiValueSource ( new OrdFieldSource ( field ) ) ; } else { vs = new MultiValueSource ( new ReverseOrdFieldSource ( field ) ) ; } Query q = new ValueSourceQuery ( vs ) ; log ( ( "test:<seq2seq4repair_space>" + q ) ) ; <START_BUG> QueryUtils . check ( q , s ) ; <END_BUG> ScoreDoc [ ] h = s . search ( q , null , 1000 ) . scoreDocs ; assertEquals ( "All<seq2seq4repair_space>docs<seq2seq4repair_space>should<seq2seq4repair_space>be<seq2seq4repair_space>matched!" , N_DOCS , h . length ) ; String prevID = ( inOrder ) ? "IE" : "IC" ; for ( int i = 0 ; i < ( h . length ) ; i ++ ) { String resID = s . doc ( h [ i ] . doc ) . get ( ID_FIELD ) ; log ( ( ( ( ( i + ".<seq2seq4repair_space>score=" ) + ( h [ i ] . score ) ) + "<seq2seq4repair_space>-<seq2seq4repair_space>" ) + resID ) ) ; log ( s . explain ( q , h [ i ] . doc ) ) ; if ( inOrder ) { assertTrue ( ( ( ( "res<seq2seq4repair_space>id<seq2seq4repair_space>" + resID ) + "<seq2seq4repair_space>should<seq2seq4repair_space>be<seq2seq4repair_space><<seq2seq4repair_space>prev<seq2seq4repair_space>res<seq2seq4repair_space>id<seq2seq4repair_space>" ) + prevID ) , ( ( resID . compareTo ( prevID ) ) < 0 ) ) ; } else { assertTrue ( ( ( ( "res<seq2seq4repair_space>id<seq2seq4repair_space>" + resID ) + "<seq2seq4repair_space>should<seq2seq4repair_space>be<seq2seq4repair_space>><seq2seq4repair_space>prev<seq2seq4repair_space>res<seq2seq4repair_space>id<seq2seq4repair_space>" ) + prevID ) , ( ( resID . compareTo ( prevID ) ) > 0 ) ) ; } prevID = resID ; } s . close ( ) ; } @ Test public void testOrdFieldExactScore ( ) throws Exception , CorruptIndexException { } @ Test public void testReverseOrdFieldExactScore ( ) throws Exception , CorruptIndexException { } private void doTestExactScore ( String field , boolean inOrder ) throws Exception , CorruptIndexException { } @ Test public void testCachingOrd ( ) throws Exception , CorruptIndexException { } @ Test public void testCachingReverseOrd ( ) throws Exception , CorruptIndexException { } private void doTestCaching ( String field , boolean inOrder ) throws Exception , CorruptIndexException { } private String testName ( ) { } }

Fix:
QueryUtils . check ( random , q , s ) ;
Buggy code:
public class ShowSprintInformationAction extends Action { public ActionForward execute ( ActionMapping mapping , ActionForm form , HttpServletRequest request , HttpServletResponse response ) { IProject project = ( ( IProject ) ( SessionManager . getProject ( request ) ) ) ; ProjectObject projectObject = SessionManager . getProjectObject ( request ) ; IUserSession userSession = ( ( IUserSession ) ( request . getSession ( ) . getAttribute ( "UserSession" ) ) ) ; request . setAttribute ( PROJECT , project ) ; String sprintID = request . getParameter ( "sprintID" ) ; SprintBacklogLogic sprintBacklogLogic = new SprintBacklogLogic ( project , userSession , sprintID ) ; SprintBacklogMapper backlog = sprintBacklogLogic . getSprintBacklogMapper ( ) ; SprintBacklogHelper sprintBacklogHelper = new SprintBacklogHelper ( project , userSession , sprintID ) ; if ( backlog == null ) { return mapping . findForward ( "error" ) ; } List < IIssue > issues = sprintBacklogHelper . getStoriesByImportance ( ) ; request . setAttribute ( "SprintID" , backlog . getSprintPlanId ( ) ) ; request . setAttribute ( "Stories" , issues ) ; NumberFormat nf = NumberFormat . getInstance ( ) ; request . setAttribute ( "StoryPoint" , nf . format ( sprintBacklogLogic . getCurrentPoint ( STORY_ISSUE_TYPE ) ) ) ; SprintPlanHelper spHelper = new SprintPlanHelper ( project ) ; ISprintPlanDesc plan = spHelper . loadPlan ( backlog . getSprintPlanId ( ) ) ; request . setAttribute ( "SprintPlan" , plan ) ; <START_BUG> request . setAttribute ( "Actors" , new ProjectMapper ( ) . getProjectScrumWorkersUsername ( projectObject . getId ( ) ) ) ; <END_BUG> String sprintPeriod = ( ( DateUtil . format ( sprintBacklogLogic . getSprintStartWorkDate ( ) , _8DIGIT_DATE_1 ) ) + "<seq2seq4repair_space>to<seq2seq4repair_space>" ) + ( DateUtil . format ( sprintBacklogLogic . getSprintEndWorkDate ( ) , _8DIGIT_DATE_1 ) ) ; request . setAttribute ( "SprintPeriod" , sprintPeriod ) ; AccountObject account = userSession . getAccount ( ) ; ScrumRole sr = new ScrumRoleLogic ( ) . getScrumRole ( project , account ) ; if ( ( sr != null ) && ( sr . getAccessSprintBacklog ( ) ) ) { return mapping . findForward ( "success" ) ; } else { return mapping . findForward ( "GuestOnly" ) ; } } }

Fix:
request . setAttribute ( "Actors" , new ProjectMapper ( ) . getProjectWorkersUsername ( projectObject . getId ( ) ) ) ;
Buggy code:
public class ServerModelDeploymentRemoveUpdate extends AbstractServerModelUpdate < ServerDeploymentActionResult > { private static final long serialVersionUID = - 3612085673646053177L ; private final String deploymentName ; private final ServerDeploymentStartStopHandler startStopHandler ; public ServerModelDeploymentRemoveUpdate ( final String deploymentName , boolean undeploy ) { } @ Override public void applyUpdate ( ServerModel standalone ) throws UpdateFailedException { } @ Override public < P > void applyUpdate ( UpdateContext updateContext , UpdateResultHandler < ? super ServerDeploymentActionResult , P > resultHandler , P param ) { if ( ( startStopHandler ) != null ) { <START_BUG> startStopHandler . undeploy ( deploymentName , updateContext , resultHandler , param ) ; <END_BUG> } } @ Override public ServerModelDeploymentAddUpdate getCompensatingUpdate ( ServerModel original ) { } }

Fix:
startStopHandler . undeploy ( deploymentName , updateContext . getServiceContainer ( ) , resultHandler , param ) ;
Buggy code:
abstract class RFC1522Codec { protected static final char SEP = '?' ; protected static final String POSTFIX = "?=" ; protected static final String PREFIX = "=?" ; protected String encodeText ( final String text , final String charset ) throws UnsupportedEncodingException , EncoderException { } protected String decodeText ( final String text ) throws UnsupportedEncodingException , DecoderException { if ( text == null ) { return null ; } if ( ( ! ( text . startsWith ( RFC1522Codec . PREFIX ) ) ) || ( ! ( text . endsWith ( RFC1522Codec . POSTFIX ) ) ) ) { throw new DecoderException ( "RFC<seq2seq4repair_space>1522<seq2seq4repair_space>violation:<seq2seq4repair_space>malformed<seq2seq4repair_space>encoded<seq2seq4repair_space>content" ) ; } int termnator = ( text . length ( ) ) - 2 ; int from = 2 ; int to = text . indexOf ( RFC1522Codec . SEP , from ) ; <START_BUG> if ( ( to == ( - 1 ) ) || ( to == termnator ) ) { <END_BUG> throw new DecoderException ( "RFC<seq2seq4repair_space>1522<seq2seq4repair_space>violation:<seq2seq4repair_space>charset<seq2seq4repair_space>token<seq2seq4repair_space>not<seq2seq4repair_space>found" ) ; } String charset = text . substring ( from , to ) ; if ( charset . equals ( "" ) ) { throw new DecoderException ( "RFC<seq2seq4repair_space>1522<seq2seq4repair_space>violation:<seq2seq4repair_space>charset<seq2seq4repair_space>not<seq2seq4repair_space>specified" ) ; } from = to + 1 ; to = text . indexOf ( RFC1522Codec . SEP , from ) ; if ( ( to == ( - 1 ) ) || ( to == termnator ) ) { throw new DecoderException ( "RFC<seq2seq4repair_space>1522<seq2seq4repair_space>violation:<seq2seq4repair_space>encoding<seq2seq4repair_space>token<seq2seq4repair_space>not<seq2seq4repair_space>found" ) ; } String encoding = text . substring ( from , to ) ; if ( ! ( getEncoding ( ) . equalsIgnoreCase ( encoding ) ) ) { throw new DecoderException ( ( ( "This<seq2seq4repair_space>codec<seq2seq4repair_space>cannot<seq2seq4repair_space>decode<seq2seq4repair_space>" + encoding ) + "<seq2seq4repair_space>encoded<seq2seq4repair_space>content" ) ) ; } from = to + 1 ; to = text . indexOf ( RFC1522Codec . SEP , from ) ; byte [ ] data = StringUtils . getBytesUsAscii ( text . substring ( from , to ) ) ; data = doDecoding ( data ) ; return new String ( data , charset ) ; } protected abstract String getEncoding ( ) { } protected abstract byte [ ] doEncoding ( byte [ ] bytes ) throws EncoderException { } protected abstract byte [ ] doDecoding ( byte [ ] bytes ) throws DecoderException { } }

Fix:
if ( to == termnator ) {
Buggy code:
public class SeriePrinter { private double [ ] verticalBorderColor = new double [ ] { 0.411 , 0.411 , 0.411 } ; private double [ ] borderColor = new double [ ] { 1.0 , 0.0 , 1.0 } ; private float lineWidth = 2.5F ; private int pointToDraw = 1000 ; public void draw ( Serie s , double minX , double maxX , double minY , double maxY ) { } public void draw ( Serie s , int numToDraw , double minX , double maxX , double minY , double maxY , float lineWidth , double [ ] borderColor ) { } private void drawVertical ( int numToDraw , double minX , double maxX , double minY , double maxY , double [ ] borderColor2 ) { } private void drawLine ( Serie s , int numToDraw , double minX , double maxX , double minY , double maxY ) { if ( ( s . size ( ) ) == 0 ) { return ; } double [ ] lineColor2 = s . getLineColor ( ) ; GL11 . glColor3d ( lineColor2 [ 0 ] , lineColor2 [ 1 ] , lineColor2 [ 2 ] ) ; double incrementX = ( maxX - minX ) // ( numToDraw - 1 ) ; double actualX = maxX ; double midY = ( maxY + minY ) // 2.0 ; <START_BUG> double scaleFactorByChartCompressionPile = ( Math . abs ( ( maxY + minY ) ) ) // 2 ; <END_BUG> double scaleY = ( s . getScaleY ( ) ) * scaleFactorByChartCompressionPile ; Point2D last = s . getLast ( ) ; double y = ( ( last . getY ( ) ) * scaleY ) + midY ; for ( int i = 1 ; i < ( Math . min ( s . size ( ) , numToDraw ) ) ; i ++ ) { Point2D point2d = s . getFromBottom ( i ) ; y = ( ( last . getY ( ) ) * scaleY ) + midY ; GL11 . glVertex3d ( actualX , y , 0 ) ; actualX -= incrementX ; y = ( ( point2d . getY ( ) ) * scaleY ) + midY ; GL11 . glVertex3d ( actualX , y , 0 ) ; last = point2d ; } } private void drawBorder ( double minX , double maxX , double minY , double maxY , double [ ] borderColor2 ) { } }

Fix:
double scaleFactorByChartCompressionPile = ( ( Math . abs ( maxY ) ) + ( Math . abs ( minY ) ) ) // 2 ;
Buggy code:
public abstract class VAJToolsServlet extends HttpServlet { class VAJLocalServletUtil extends VAJLocalUtil { public void log ( String msg , int level ) { } } public static final String DIR_PARAM = "dir" ; public static final String INCLUDE_PARAM = "include" ; public static final String EXCLUDE_PARAM = "exclude" ; public static final String CLASSES_PARAM = "cls" ; public static final String SOURCES_PARAM = "src" ; public static final String RESOURCES_PARAM = "res" ; public static final String DEFAULT_EXCLUDES_PARAM = "dex" ; public static final String PROJECT_NAME_PARAM = "project" ; HttpServletRequest request ; HttpServletResponse response ; VAJUtil util ; protected abstract void executeRequest ( ) { } public void doGet ( HttpServletRequest req , HttpServletResponse res ) throws ServletException , IOException { try { response = res ; request = req ; initRequest ( ) ; executeRequest ( ) ; } catch ( BuildException e ) { <START_BUG> util . log ( ( "Error<seq2seq4repair_space>occured:<seq2seq4repair_space>" + ( e . getMessage ( ) ) ) , MSG_ERR ) ; <END_BUG> } catch ( Exception e ) { try { if ( ! ( e instanceof BuildException ) ) { String trace = StringUtils . getStackTrace ( e ) ; util . log ( ( ( ( "Program<seq2seq4repair_space>error<seq2seq4repair_space>in<seq2seq4repair_space>" + ( this . getClass ( ) . getName ( ) ) ) + ":\n" ) + trace ) , MSG_ERR ) ; } } catch ( Throwable t ) { t . printStackTrace ( ) ; } finally { if ( ! ( e instanceof BuildException ) ) { throw new ServletException ( e . getMessage ( ) ) ; } } } } protected void initRequest ( ) throws IOException { } VAJUtil getUtil ( ) { } protected boolean getBooleanParam ( String param ) { } protected boolean getBooleanParam ( String param , boolean defaultValue ) { } protected String getFirstParamValueString ( String param ) { } protected String [ ] getParamValues ( String param ) { } protected boolean toBoolean ( String string ) { } }

Fix:
util . log ( ( "Error<seq2seq4repair_space>occurred:<seq2seq4repair_space>" + ( e . getMessage ( ) ) ) , MSG_ERR ) ;
Buggy code:
public class UserType extends DataType implements UserDataValue { private Object value ; private static final int BASE_MEMORY_USAGE = ClassSize . estimateBaseFromCatalog ( UserType . class ) ; public int estimateMemoryUsage ( ) { } public String getString ( ) { } public boolean getBoolean ( ) throws StandardException { } public byte getByte ( ) throws StandardException { } public short getShort ( ) throws StandardException { } public int getInt ( ) throws StandardException { } public long getLong ( ) throws StandardException { } public float getFloat ( ) throws StandardException { } public double getDouble ( ) throws StandardException { } public BigDecimal getBigDecimal ( ) throws StandardException { if ( ! ( isNull ( ) ) ) { if ( ( value ) instanceof BigDecimal ) return ( ( BigDecimal ) ( value ) ) ; if ( ( value ) instanceof Number ) <START_BUG> return new BigDecimal ( ( ( Number ) ( value ) ) . doubleValue ( ) ) ; <END_BUG> } return super . getBigDecimal ( ) ; } public byte [ ] getBytes ( ) throws StandardException { } public Date getDate ( Calendar cal ) throws StandardException { } public Time getTime ( Calendar cal ) throws StandardException { } public Timestamp getTimestamp ( Calendar cal ) throws StandardException { } public Object getObject ( ) { } public void setObjectForCast ( Object theValue , boolean instanceOfResultType , String resultTypeClassName ) throws StandardException { } public int getLength ( ) { } public String getTypeName ( ) { } public int getTypeFormatId ( ) { } public void writeExternal ( ObjectOutput out ) throws IOException { } public void readExternal ( ObjectInput in ) throws IOException , ClassNotFoundException { } public void readExternalFromArray ( ArrayInputStream in ) throws IOException , ClassNotFoundException { } public DataValueDescriptor getClone ( ) { } public DataValueDescriptor getNewNull ( ) { } public void restoreToNull ( ) { } public void setValueFromResultSet ( ResultSet resultSet , int colNumber , boolean isNullable ) throws SQLException { } public int compare ( DataValueDescriptor other ) throws StandardException { } public boolean compare ( int op , DataValueDescriptor other , boolean orderedNulls , boolean unknownRV ) throws StandardException { } public UserType ( ) { } public UserType ( Object value ) { } public void setValue ( Object value ) { } protected void setFrom ( DataValueDescriptor theValue ) throws StandardException { } public void setBigDecimal ( Number theValue ) { } public void setValue ( String theValue ) { } public BooleanDataValue equals ( DataValueDescriptor left , DataValueDescriptor right ) throws StandardException { } public BooleanDataValue notEquals ( DataValueDescriptor left , DataValueDescriptor right ) throws StandardException { } public String toString ( ) { } public int hashCode ( ) { } public int typePrecedence ( ) { } public final boolean isNull ( ) { } }

Fix:
return new BigDecimal ( Double . toString ( ( ( Number ) ( value ) ) . doubleValue ( ) ) ) ;
Buggy code:
class ShortHandPointer implements XPointerPart { private String fShortHandPointer ; private boolean fIsFragmentResolved = false ; private SymbolTable fSymbolTable ; public ShortHandPointer ( ) { } public ShortHandPointer ( SymbolTable symbolTable ) { } public void parseXPointer ( String part ) throws XNIException { } int fMatchingChildCount = 0 ; public boolean resolveXPointer ( QName element , XMLAttributes attributes , Augmentations augs , int event ) throws XNIException { } private boolean hasMatchingIdentifier ( QName element , XMLAttributes attributes , Augmentations augs , int event ) throws XNIException { } public String getDTDDeterminedID ( XMLAttributes attributes , int index ) throws XNIException { } public String getSchemaDeterminedID ( XMLAttributes attributes , int index ) throws XNIException { } public String getChildrenSchemaDeterminedID ( XMLAttributes attributes , int index ) throws XNIException { } public boolean isFragmentResolved ( ) { } public boolean isChildFragmentResolved ( ) { <START_BUG> return ( fIsFragmentResolved ) & ( ( fMatchingChildCount ) > 0 ) ; <END_BUG> } public String getSchemeName ( ) { } public String getSchemeData ( ) { } public void setSchemeName ( String schemeName ) { } public void setSchemeData ( String schemeData ) { } }

Fix:
return ( fIsFragmentResolved ) && ( ( fMatchingChildCount ) > 0 ) ;
Buggy code:
public class JSLPNamespace extends Namespace { private static final String JSLP_SCHEME = "jslp" ; private static final long serialVersionUID = - 3041453162456476102L ; public static final String NAME = "ecf.namespace.slp" ; public ID createInstance ( Object [ ] parameters ) throws IDCreateException { if ( ( ( parameters == null ) || ( ( parameters . length ) < 1 ) ) || ( ( parameters . length ) > 2 ) ) { throw new IDCreateException ( Messages . JSLPNamespace_2 ) ; } else if ( ( ( parameters [ 0 ] ) == null ) || ( parameters [ 0 ] . equals ( "" ) ) ) { throw new IDCreateException ( Messages . JSLPNamespace_3 ) ; } else if ( ( parameters [ 0 ] ) instanceof ServiceURL ) { ServiceURL anURL = ( ( ServiceURL ) ( parameters [ 0 ] ) ) ; <START_BUG> JSLPServiceTypeID stid = new JSLPServiceTypeID ( this , anURL ) ; <END_BUG> return new JSLPServiceID ( this , stid , anURL . getHost ( ) ) ; } else if ( ( parameters [ 0 ] ) instanceof JSLPServiceID ) { return ( ( ID ) ( parameters [ 0 ] ) ) ; } else if ( ( parameters [ 0 ] ) instanceof IServiceID ) { IServiceID anId = ( ( IServiceID ) ( parameters [ 0 ] ) ) ; return createInstance ( new Object [ ] { anId . getServiceTypeID ( ) , parameters [ 1 ] } ) ; } else if ( ( parameters [ 0 ] ) instanceof IServiceTypeID ) { IServiceTypeID stid = ( ( IServiceTypeID ) ( parameters [ 0 ] ) ) ; return createInstance ( new Object [ ] { stid . getName ( ) , parameters [ 1 ] } ) ; } else if ( ( parameters [ 0 ] ) instanceof String ) { String type = ( ( String ) ( parameters [ 0 ] ) ) ; IServiceTypeID stid = null ; if ( StringUtils . contains ( type , "._" ) ) { ServiceTypeID aStid = new ServiceTypeID ( this , type ) ; stid = new JSLPServiceTypeID ( this , aStid ) ; } else { stid = new JSLPServiceTypeID ( this , type ) ; } String name = null ; if ( ( parameters . length ) > 1 ) { try { name = ( ( String ) ( parameters [ 1 ] ) ) ; } catch ( final ClassCastException e ) { throw new IDCreateException ( Messages . JSLPNamespace_4 ) ; } } return new JSLPServiceID ( this , stid , name ) ; } else { throw new IDCreateException ( Messages . JSLPNamespace_3 ) ; } } public String getScheme ( ) { } public Class [ ] [ ] getSupportedParameterTypes ( ) { } }

Fix:
JSLPServiceTypeID stid = new JSLPServiceTypeID ( this , anURL , ( ( String [ ] ) ( parameters [ 1 ] ) ) ) ;
Buggy code:
public class AjaxIndicatorAppender extends AbstractBehavior { private Component component ; private static final long serialVersionUID = 1L ; public AjaxIndicatorAppender ( ) { } @ Override public void renderHead ( IHeaderResponse response ) { } @ Override public void onRendered ( Component component ) { } protected CharSequence getIndicatorUrl ( ) { IRequestHandler handler = new org . apache . wicket . request . handler . resource . ResourceReferenceRequestHandler ( AbstractDefaultAjaxBehavior . INDICATOR ) ; <START_BUG> return RequestCycle . get ( ) . renderUrlFor ( handler ) ; <END_BUG> } protected String getSpanClass ( ) { } public String getMarkupId ( ) { } @ Override public final void bind ( Component component ) { } }

Fix:
return RequestCycle . get ( ) . urlFor ( handler ) ;
Buggy code:
public final class HTTPSamplerFactory { public static final String HTTP_SAMPLER_JAVA = "HTTPSampler" ; public static final String HTTP_SAMPLER_APACHE = "HTTPSampler2" ; public static final String IMPL_HTTP_CLIENT4 = "HttpClient4" ; public static final String IMPL_HTTP_CLIENT3_1 = "HttpClient3.1" ; public static final String IMPL_JAVA = "Java" ; public static final String DEFAULT_CLASSNAME = JMeterUtils . getPropDefault ( "jmeter.httpsampler" , HTTPSamplerFactory . IMPL_HTTP_CLIENT4 ) ; private HTTPSamplerFactory ( ) { } public static HTTPSamplerBase newInstance ( ) { } public static HTTPSamplerBase newInstance ( String alias ) { if ( ( alias == null ) || ( ( alias . length ( ) ) == 0 ) ) { <START_BUG> alias = HTTPSamplerFactory . DEFAULT_CLASSNAME ; <END_BUG> } if ( ( alias . equals ( HTTPSamplerFactory . HTTP_SAMPLER_JAVA ) ) || ( alias . equals ( HTTPSamplerFactory . IMPL_JAVA ) ) ) { return new HTTPSamplerProxy ( HTTPSamplerFactory . IMPL_JAVA ) ; } if ( ( alias . equals ( HTTPSamplerFactory . HTTP_SAMPLER_APACHE ) ) || ( alias . equals ( HTTPSamplerFactory . IMPL_HTTP_CLIENT3_1 ) ) ) { return new HTTPSamplerProxy ( HTTPSamplerFactory . IMPL_HTTP_CLIENT3_1 ) ; } if ( alias . equals ( HTTPSamplerFactory . IMPL_HTTP_CLIENT4 ) ) { return new HTTPSamplerProxy ( HTTPSamplerFactory . IMPL_HTTP_CLIENT4 ) ; } throw new IllegalArgumentException ( ( ( "Unknown<seq2seq4repair_space>sampler<seq2seq4repair_space>type:<seq2seq4repair_space>'" + alias ) + "'" ) ) ; } public static String [ ] getImplementations ( ) { } public static HTTPAbstractImpl getImplementation ( String impl , HTTPSamplerBase base ) { } }

Fix:
return new HTTPSamplerProxy ( ) ;
Buggy code:
public class WebResponseExceptionsTest extends WicketTestCase { public void testBufferedExceptionErrorPage ( ) { } public void testExceptionErrorPage ( ) { } public void testExpirePage ( ) { } public void testInternalErrorPage ( ) { tester . startPage ( TestErrorPage . class ) ; AjaxLink link = ( ( AjaxLink ) ( tester . getComponentFromLastRenderedPage ( "link" ) ) ) ; tester . createRequestCycle ( ) ; <START_BUG> String callbackUrl = ( ( org . apache . wicket . ajax . AjaxEventBehavior ) ( link . getBehaviors ( ) . get ( 0 ) ) ) . getCallbackUrl ( ) . toString ( ) ; <END_BUG> tester . setupRequestAndResponse ( ) ; tester . getServletRequest ( ) . addHeader ( "Wicket-Ajax" , "Yes" ) ; tester . getServletRequest ( ) . setURL ( callbackUrl ) ; WebRequestCycle cycle = tester . createRequestCycle ( ) ; cycle . request ( ) ; tester . assertAjaxLocation ( ) ; } }

Fix:
String callbackUrl = ( ( org . apache . wicket . ajax . AjaxEventBehavior ) ( link . getBehaviors ( ) . get ( 0 ) ) ) . getCallbackUrl ( ) . toString ( ) . replaceAll ( "&amp;" , "&" ) ;
Buggy code:
public class IndexingParser extends SourceElementParser { SingleNameReference singleNameReference = new SingleNameReference ( CharOperation . NO_CHAR , 0 ) ; QualifiedNameReference qualifiedNameReference = new QualifiedNameReference ( CharOperation . NO_CHAR_CHAR , new long [ 0 ] , 0 , 0 ) ; ImportReference importReference = new ImportReference ( CharOperation . NO_CHAR_CHAR , new long [ 1 ] , false , 0 ) ; public IndexingParser ( ISourceElementRequestor requestor , IProblemFactory problemFactory , CompilerOptions options , boolean reportLocalDeclarations , boolean optimizeStringLiterals , boolean useSourceJavadocParser ) { } protected ImportReference newImportReference ( char [ ] [ ] tokens , long [ ] sourcePositions , boolean onDemand , int mod ) { ImportReference ref = this . importReference ; ref . tokens = tokens ; ref . sourcePositions = sourcePositions ; if ( onDemand ) { ref . bits |= ASTNode . OnDemand ; } ref . sourceEnd = ( ( int ) ( ( sourcePositions [ ( ( sourcePositions . length ) - 1 ) ] ) & - 1 ) ) ; ref . sourceStart = ( ( int ) ( ( sourcePositions [ 0 ] ) > > > 32 ) ) ; <START_BUG> ref . modifiers = modifiers ; <END_BUG> return ref ; } protected SingleNameReference newSingleNameReference ( char [ ] source , long positions ) { } protected QualifiedNameReference newQualifiedNameReference ( char [ ] [ ] tokens , long [ ] positions , int sourceStart , int sourceEnd ) { } }

Fix:
ref . modifiers = this . modifiers ;
Buggy code:
public class Main { public static void main ( String [ ] args ) { <START_BUG> PigGame g = new PigGame ( 18 ) ; <END_BUG> g . playGame ( ) ; System . out . println ( g . getScore ( ) ) ; System . out . println ( g . getNumTurns ( ) ) ; System . out . println ( g . getTurnAverage ( ) ) ; } No newline ; at end ; of file ; }

Fix:
PigGame g = new PigGame ( 25 ) ;
Buggy code:
public class AddEvent extends Activity { private DBManager db ; private TextView eventTitle ; private TextView eventDate ; private EditText enterTitle ; private DatePicker enterDate ; private Button addEvent ; private String title ; private String date ; @ Override public void onCreate ( Bundle savedInstanceState ) { } OnClickListener buttonAddOnClickListener ; public void getData ( ) { } @ SuppressLint ( "SimpleDateFormat" ) public boolean dateIsInThePast ( ) { } public boolean onOptionsItemSelected ( MenuItem item ) { switch ( item . getItemId ( ) ) { case id . home : NavUtils . navigateUpFromSameTask ( this ) ; <START_BUG> overridePendingTransition ( slide_out_left_to_right , slide_in_left_to_right ) ; <END_BUG> return true ; } return super . onOptionsItemSelected ( item ) ; } @ Override public void onBackPressed ( ) { } @ Override protected void onDestroy ( ) { } @ Override protected void onPause ( ) { } No newline ; at end ; of file ; }

Fix:
overridePendingTransition ( slide_in_left_to_right , slide_out_left_to_right ) ;
Buggy code:
public class MutableShort extends Number implements Comparable < MutableShort > , Mutable < Number > { private static final long serialVersionUID = - 2135791679L ; private short value ; public MutableShort ( ) { } public MutableShort ( final short value ) { } public MutableShort ( final Number value ) { } public MutableShort ( final String value ) throws NumberFormatException { } @ Override public Short getValue ( ) { } public void setValue ( final short value ) { } @ Override public void setValue ( final Number value ) { } public void increment ( ) { } public void decrement ( ) { } public void add ( final short operand ) { } public void add ( final Number operand ) { } public void subtract ( final short operand ) { } public void subtract ( final Number operand ) { } @ Override public short shortValue ( ) { } @ Override public int intValue ( ) { } @ Override public long longValue ( ) { } @ Override public float floatValue ( ) { } @ Override public double doubleValue ( ) { } public Short toShort ( ) { } @ Override public boolean equals ( final Object obj ) { } @ Override public int hashCode ( ) { } @ Override public int compareTo ( final MutableShort other ) { <START_BUG> short anotherVal = other . value ; <END_BUG> return ( value ) < anotherVal ? - 1 : ( value ) == anotherVal ? 0 : 1 ; } @ Override public String toString ( ) { } }

Fix:
final short anotherVal = other . value ;
Buggy code:
public final class SSLTrustManager { public enum SslFailureReason { CERT_NOT_TRUSTED , CERT_CHANGED ; } private static final String DEBUG_TAG = "SSLTrustManager" ; private X509TrustManager defaultTrustManager ; private Map < Account , SSLTrustManager . SecureX509TrustManager > managers = Maps . newHashMap ( ) ; private Map < Account , SSLSocketFactory > cachedFactories = Maps . newHashMap ( ) ; private static SSLTrustManager instance ; private SSLTrustManager ( ) { } public static synchronized SSLTrustManager instance ( ) { } private void init ( ) { } public synchronized TrustManager [ ] getTrustManagers ( Account account ) { } public synchronized SSLSocketFactory getSSLSocketFactory ( Account account ) { } public List < X509Certificate > getCertsChainForAccount ( Account account ) { } public X509Certificate getCertificateInfo ( Account account ) throws CertificateParsingException { } public SSLTrustManager . SslFailureReason getFailureReason ( Account account ) { } public List < X509Certificate > orderCerts ( X509Certificate [ ] certificates ) { } private class SecureX509TrustManager implements X509TrustManager { private Account account ; private SSLTrustManager . SslFailureReason reason ; private volatile List < X509Certificate > certsChain = ImmutableList . of ( ) ; public SecureX509TrustManager ( Account account ) { } public List < X509Certificate > getServerCertsChain ( ) { } public SSLTrustManager . SslFailureReason getReason ( ) { } @ Override public void checkClientTrusted ( X509Certificate [ ] chain , String authType ) throws CertificateException { } @ Override public void checkServerTrusted ( X509Certificate [ ] chain , String authType ) throws CertificateException { } public String getCeritificateInfo ( ) throws CertificateParsingException { } private void validateHostName ( List < X509Certificate > chain ) throws CertificateException { X509Certificate cert = chain . get ( 0 ) ; X509HostnameVerifier mHostnameVerifier = new BrowserCompatHostnameVerifier ( ) ; try { <START_BUG> mHostnameVerifier . verify ( account . getServerHost ( ) , cert ) ; <END_BUG> } catch ( SSLException e ) { throw new CertificateException ( ) ; } } private void customCheck ( List < X509Certificate > chain , String authType ) throws CertificateException { } public X509Certificate [ ] getAcceptedIssuers ( ) { } @ Override protected void finalize ( ) { } } public Map < Account , SSLSocketFactory > getCachedFactories ( ) { } }

Fix:
mHostnameVerifier . verify ( account . getServerDomainName ( ) , cert ) ;
Buggy code:
public class Tournament { private static int numOfGames = 100 ; public static boolean debug = false ; public static void main ( String [ ] args ) { Timer timer = new Timer ( ) ; timer . startTimer ( ) ; int whiteWins = 0 ; int blackWins = 0 ; int draws = 0 ; int score ; <START_BUG> Player whitePlayer = new com . rahul . othello . players . IdealPlayer ( Coin . black , Difficulty . medium , Algorithm . alphaBeta ) ; <END_BUG> Player blackPlayer = new com . rahul . othello . players . IdealPlayer ( Coin . black , Difficulty . medium , Algorithm . minimax ) ; for ( int i = 0 ; i < ( Tournament . numOfGames ) ; i ++ ) { score = new Game ( whitePlayer , blackPlayer ) . play ( ) ; if ( score == 1 ) whiteWins ++ ; else if ( score == 0 ) draws ++ ; else blackWins ++ ; } timer . stopTimer ( ) ; System . out . printf ( "%50s<seq2seq4repair_space>%3d%n" , "Total<seq2seq4repair_space>games<seq2seq4repair_space>played" , Tournament . numOfGames ) ; System . out . printf ( "%50s<seq2seq4repair_space>%3d%n" , ( ( whitePlayer . getName ( ) ) + "<seq2seq4repair_space>wins" ) , whiteWins ) ; System . out . printf ( "%50s<seq2seq4repair_space>%3d%n" , "Games<seq2seq4repair_space>drawn" , draws ) ; System . out . printf ( "%50s<seq2seq4repair_space>%3d%n" , ( ( blackPlayer . getName ( ) ) + "<seq2seq4repair_space>wins" ) , blackWins ) ; System . out . printf ( "%50s<seq2seq4repair_space>%3.2f%n" , "Elapsed<seq2seq4repair_space>time<seq2seq4repair_space>(seconds)" , timer . getElapsedTime ( ) ) ; } }

Fix:
Player whitePlayer = new com . rahul . othello . players . IdealPlayer ( Coin . white , Difficulty . medium , Algorithm . alphaBeta ) ;
Buggy code:
public class AuthMethodParser { public static final String UTF_8 = "UTF-8" ; public static List < AuthMethodConfig > parse ( final String methods , final Map < String , String > replacements ) { try { if ( ( methods == null ) || ( methods . isEmpty ( ) ) ) { return Collections . emptyList ( ) ; } final List < AuthMethodConfig > ret = new ArrayList < AuthMethodConfig > ( ) ; String [ ] parts = methods . split ( "," ) ; for ( String part : parts ) { if ( part . isEmpty ( ) ) { continue ; } int index = part . indexOf ( '?' ) ; if ( index == ( - 1 ) ) { ret . add ( AuthMethodParser . createAuthMethodConfig ( part , replacements ) ) ; } else { final String name = part . substring ( 0 , index ) ; <START_BUG> Map < String , Deque < String > > props = QueryParameterUtils . parseQueryString ( part . substring ( ( index + 1 ) ) , AuthMethodParser . UTF_8 ) ; <END_BUG> final AuthMethodConfig authMethodConfig = AuthMethodParser . createAuthMethodConfig ( name , replacements ) ; for ( Map . Entry < String , Deque < String > > entry : props . entrySet ( ) ) { Deque < String > val = entry . getValue ( ) ; if ( val . isEmpty ( ) ) { authMethodConfig . getProperties ( ) . put ( URLDecoder . decode ( entry . getKey ( ) , AuthMethodParser . UTF_8 ) , "" ) ; } else { authMethodConfig . getProperties ( ) . put ( URLDecoder . decode ( entry . getKey ( ) , AuthMethodParser . UTF_8 ) , URLDecoder . decode ( val . getFirst ( ) , AuthMethodParser . UTF_8 ) ) ; } } ret . add ( authMethodConfig ) ; } } return ret ; } catch ( UnsupportedEncodingException e ) { throw new RuntimeException ( e ) ; } } private static AuthMethodConfig createAuthMethodConfig ( String part , Map < String , String > replacements ) throws UnsupportedEncodingException { } private AuthMethodParser ( ) { } }

Fix:
Map < String , Deque < String > > props = QueryParameterUtils . parseQueryString ( part . substring ( ( index + 1 ) ) ) ;
Buggy code:
public class MarkAsExpungedAction extends FrameAction implements SelectionListener { public MarkAsExpungedAction ( AbstractFrameController frameController ) { } public void actionPerformed ( ActionEvent evt ) { <START_BUG> FolderCommandReference [ ] r = ( ( org . columba . mail . gui . frame . AbstractMailFrameController ) ( getFrameController ( ) ) ) . getTableSelection ( ) ; <END_BUG> r [ 0 ] . setMarkVariant ( MARK_AS_EXPUNGED ) ; MarkMessageCommand c = new MarkMessageCommand ( r ) ; processor . addOp ( c ) ; } public void selectionChanged ( SelectionChangedEvent e ) { } }

Fix:
FolderCommandReference [ ] r = ( ( org . columba . mail . gui . frame . AbstractMailFrameController ) ( getFrameMediator ( ) ) ) . getTableSelection ( ) ;