nus-yam/ex-repair huggingface dataset:
Program: 80664
Project: 80664
Buggy source:
private void loadMessages(){
  Database db=Database.getInstance();
  try (ResultSet messageRS=db.execSelectWhereInsecure(KonMessage.TABLE,KonMessage.COL_CHAT_ID + "String_Node_Str" + mChat.getID())){
    while (messageRS.next()) {
      KonMessage message=KonMessage.load(messageRS,mChat);
      if (message.getTransmissions().length == 0)       continue;
      this.addSilent(message);
    }
  }
 catch (  SQLException ex) {
    LOGGER.log(Level.WARNING,"String_Node_Str",ex);
  }
}

Fixed version (ground truth):
private void loadMessages(){
  LOGGER.config("String_Node_Str" + mChat.getID());
  Database db=Database.getInstance();
  try (ResultSet messageRS=db.execSelectWhereInsecure(KonMessage.TABLE,KonMessage.COL_CHAT_ID + "String_Node_Str" + mChat.getID())){
    while (messageRS.next()) {
      KonMessage message=KonMessage.load(messageRS,mChat);
      if (message.getTransmissions().length == 0)       continue;
      this.addSilent(message);
    }
  }
 catch (  SQLException ex) {
    LOGGER.log(Level.WARNING,"String_Node_Str",ex);
  }
}
Program: 80666
Project: 80666
Buggy source:
private static TrayIcon createTrayIcon(final View view,final MainFrame mainFrame){
  final WebPopupMenu popup=new WebPopupMenu("String_Node_Str");
  WebMenuItem quitItem=new WebMenuItem(Tr.tr("String_Node_Str"));
  quitItem.addActionListener(new ActionListener(){
    @Override public void actionPerformed(    ActionEvent event){
      view.callShutDown();
    }
  }
);
  popup.add(quitItem);
  final WebDialog hiddenDialog=new WebDialog();
  hiddenDialog.setUndecorated(true);
  MouseListener listener=new MouseAdapter(){
    @Override public void mousePressed(    MouseEvent e){
    }
    @Override public void mouseReleased(    MouseEvent e){
      if (e.getButton() == MouseEvent.BUTTON1)       mainFrame.toggleState();
 else       check(e);
    }
    private void check(    MouseEvent e){
      hiddenDialog.setVisible(true);
      popup.setLocation(e.getX() - 20,e.getY() - 40);
      popup.setInvoker(hiddenDialog);
      popup.setCornerWidth(0);
      popup.setVisible(true);
    }
  }
;
  TrayIcon trayIcon=new TrayIcon(getTrayImage(),"String_Node_Str");
  trayIcon.setImageAutoSize(true);
  trayIcon.addMouseListener(listener);
  return trayIcon;
}

Fixed version (ground truth):
private static TrayIcon createTrayIcon(final View view,final MainFrame mainFrame){
  final WebPopupMenu popup=new WebPopupMenu();
  WebMenuItem quitItem=new WebMenuItem(Tr.tr("String_Node_Str"));
  quitItem.addActionListener(new ActionListener(){
    @Override public void actionPerformed(    ActionEvent event){
      view.callShutDown();
    }
  }
);
  popup.add(quitItem);
  final WebDialog hiddenDialog=new WebDialog();
  hiddenDialog.setUndecorated(true);
  MouseListener listener=new MouseAdapter(){
    @Override public void mousePressed(    MouseEvent e){
    }
    @Override public void mouseReleased(    MouseEvent e){
      if (e.getButton() == MouseEvent.BUTTON1)       mainFrame.toggleState();
 else       check(e);
    }
    private void check(    MouseEvent e){
      hiddenDialog.setVisible(true);
      popup.setLocation(e.getX() - 20,e.getY() - 40);
      popup.setInvoker(hiddenDialog);
      popup.setCornerWidth(0);
      popup.setVisible(true);
    }
  }
;
  TrayIcon trayIcon=new TrayIcon(getTrayImage(),"String_Node_Str");
  trayIcon.setImageAutoSize(true);
  trayIcon.addMouseListener(listener);
  return trayIcon;
}
Program: 80668
Project: 80668
Buggy source:
private void showPopup(final WebToggleButton invoker){
  Optional<KonThread> optThread=ThreadView.this.getCurrentThread();
  if (!optThread.isPresent())   return;
  if (mPopup == null)   mPopup=new ComponentUtils.ModalPopup(invoker);
  mPopup.add(new ThreadDetails(mPopup,optThread.get()));
  mPopup.showPopup();
}

Fixed version (ground truth):
private void showPopup(final WebToggleButton invoker){
  Optional<KonThread> optThread=ThreadView.this.getCurrentThread();
  if (!optThread.isPresent())   return;
  if (mPopup == null)   mPopup=new ComponentUtils.ModalPopup(invoker);
  mPopup.removeAll();
  mPopup.add(new ThreadDetails(mPopup,optThread.get()));
  mPopup.showPopup();
}
Program: 80669
Project: 80669
Buggy source:
public void setPassword(char[] newPassword) throws KonException {
  byte[] privateKeyData=readBytesFromFile(PRIVATE_KEY_FILENAME);
  char[] oldPassword=mConf.getString(Config.ACC_PASS).toCharArray();
  writePrivateKey(privateKeyData,oldPassword,newPassword);
  mConf.setProperty(Config.ACC_PASS,"String_Node_Str");
}

Fixed version (ground truth):
public void setPassword(char[] newPassword) throws KonException {
  byte[] privateKeyData=readArmoredFile(PRIVATE_KEY_FILENAME);
  char[] oldPassword=mConf.getString(Config.ACC_PASS).toCharArray();
  writePrivateKey(privateKeyData,oldPassword,newPassword);
  mConf.setProperty(Config.ACC_PASS,"String_Node_Str");
}
Program: 80670
Project: 80670
Buggy source:
private PersonalKey load() throws KonException {
  byte[] publicKeyData=readBytesFromFile(PUBLIC_KEY_FILENAME);
  byte[] privateKeyData=readBytesFromFile(PRIVATE_KEY_FILENAME);
  byte[] bridgeCertData=readBytesFromFile(BRIDGE_CERT_FILENAME);
  char[] password=mConf.getString(Config.ACC_PASS).toCharArray();
  try {
    return PersonalKey.load(disarm(privateKeyData),disarm(publicKeyData),password,bridgeCertData);
  }
 catch (  PGPException|IOException|CertificateException|NoSuchProviderException ex) {
    LOGGER.log(Level.WARNING,"String_Node_Str",ex);
    throw new KonException(KonException.Error.RELOAD_KEY,ex);
  }
}

Fixed version (ground truth):
private PersonalKey load() throws KonException {
  byte[] publicKeyData=readArmoredFile(PUBLIC_KEY_FILENAME);
  byte[] privateKeyData=readArmoredFile(PRIVATE_KEY_FILENAME);
  byte[] bridgeCertData=readFile(BRIDGE_CERT_FILENAME);
  char[] password=mConf.getString(Config.ACC_PASS).toCharArray();
  try {
    mKey=PersonalKey.load(privateKeyData,publicKeyData,password,bridgeCertData);
  }
 catch (  PGPException|IOException|CertificateException|NoSuchProviderException ex) {
    LOGGER.log(Level.WARNING,"String_Node_Str",ex);
    throw new KonException(KonException.Error.RELOAD_KEY,ex);
  }
  return mKey;
}
Program: 80671
Project: 80671
Buggy source:
public void setNewPassword(char[] oldPassword,char[] newPassword) throws KonException {
  byte[] privateKeyData=readBytesFromFile(PRIVATE_KEY_FILENAME);
  writePrivateKey(privateKeyData,oldPassword,newPassword);
  mConf.setProperty(Config.ACC_PASS,"String_Node_Str");
}

Fixed version (ground truth):
public void setNewPassword(char[] oldPassword,char[] newPassword) throws KonException {
  byte[] privateKeyData=readArmoredFile(PRIVATE_KEY_FILENAME);
  writePrivateKey(privateKeyData,oldPassword,newPassword);
  mConf.setProperty(Config.ACC_PASS,"String_Node_Str");
}
Program: 80673
Project: 80673
Buggy source:
@Override protected void updateOnEDT(Object arg){
  this.update(arg);
  MessageList table=MessageList.this;
  int row;
  for (row=table.getRowCount() - 1; row >= 0; row--)   if (this == table.getModel().getValueAt(row,0))   break;
  table.setHeight(row);
  if (row == table.getRowCount() - 1)   table.mScrollDownOnResize=true;
}

Fixed version (ground truth):
@Override protected void updateOnEDT(Object arg){
  this.updateView(arg);
  MessageList table=MessageList.this;
  int row;
  for (row=table.getRowCount() - 1; row >= 0; row--)   if (this == table.getModel().getValueAt(row,0))   break;
  table.setHeight(row);
  if (row == table.getRowCount() - 1)   table.mScrollDownOnResize=true;
}
Program: 80674
Project: 80674
Buggy source:
Optional<BufferedImage> updateNowOrLater(){
  int width=mParent.getWidth();
  int height=mParent.getHeight();
  if (mCached == null || mCached.getWidth() != width || mCached.getHeight() != height) {
    Image scaledImage=scale(mOrigin,width,height,true);
    if (scaledImage.getWidth(this) != -1)     this.updateCachedBG(scaledImage);
  }
  return Optional.ofNullable(mCached);
}

Fixed version (ground truth):
/** 
 * Update the background image for this parent. Returns immediately, but repaints parent if updating is done asynchronously.
 * @return if synchronized update is possible the updated image, else anold image if present
 */
Optional<BufferedImage> updateNowOrLater(){
  if (mCached == null || mCached.getWidth() != mParent.getWidth() || mCached.getHeight() != mParent.getHeight()) {
    if (this.loadOrigin()) {
      this.scaleOrigin();
    }
  }
  return Optional.ofNullable(mCached);
}
Program: 80675
Project: 80675
Buggy source:
/** 
 * Scale image down to maximum or minimum of width or height, preserving ratio.
 * @param max specifies if image is scaled to maximum or minimum of width/height
 */
private static Image scale(Image image,int width,int height,boolean max){
  int iw=image.getWidth(null);
  int ih=image.getHeight(null);
  if (max && (iw <= width || ih <= height) || !max && (iw <= width && ih <= height))   return image;
  double sw=width / (iw * 1.0);
  double sh=height / (ih * 1.0);
  double scale=max ? Math.max(sw,sh) : Math.min(sw,sh);
  return image.getScaledInstance((int)(iw * scale),(int)(ih * scale),Image.SCALE_FAST);
}

Fixed version (ground truth):
/** 
 * Scale image down to maximum or minimum of width or height, preserving ratio.
 * @param max specifies if image is scaled to maximum or minimum of width/height
 * @return the scaled image, loaded async
 */
private static Image scale(Image image,int width,int height,boolean max){
  int iw=image.getWidth(null);
  int ih=image.getHeight(null);
  if (iw == -1)   LOGGER.warning("String_Node_Str");
  if (max && (iw <= width || ih <= height) || !max && (iw <= width && ih <= height))   return image;
  double sw=width / (iw * 1.0);
  double sh=height / (ih * 1.0);
  double scale=max ? Math.max(sw,sh) : Math.min(sw,sh);
  return image.getScaledInstance((int)(iw * scale),(int)(ih * scale),Image.SCALE_FAST);
}
Program: 80676
Project: 80676
Buggy source:
@Override public boolean imageUpdate(Image img,int infoflags,int x,int y,int w,int h){
  if ((infoflags & ImageObserver.ALLBITS) == 0) {
    return true;
  }
  this.updateCachedBG(img);
  mParent.repaint();
  return false;
}

Fixed version (ground truth):
@Override public boolean imageUpdate(Image img,int infoflags,int x,int y,int w,int h){
  if ((infoflags & ImageObserver.ALLBITS) == 0) {
    return true;
  }
  if (img.equals(mOrigin)) {
    boolean sync=this.scaleOrigin();
    if (sync)     mParent.repaint();
    return false;
  }
 else {
    this.updateCachedBG(img);
    mParent.repaint();
    return false;
  }
}
Program: 80677
Project: 80677
Buggy source:
private void updateCachedBG(Image scaledImage){
  int width=mParent.getWidth();
  int height=mParent.getHeight();
  mCached=new BufferedImage(width,height,BufferedImage.TYPE_INT_ARGB);
  Graphics2D cachedG=mCached.createGraphics();
  if (mBottomColor != null) {
    GradientPaint p2=new GradientPaint(0,0,new Color(0,0,0,0),0,height,mBottomColor);
    cachedG.setPaint(p2);
    cachedG.fillRect(0,0,width,getHeight());
  }
  int iw=scaledImage.getWidth(this);
  int ih=scaledImage.getHeight(this);
  if (iw > 0 && ih > 0) {
    for (int x=0; x < width; x+=iw) {
      for (int y=0; y < height; y+=ih) {
        cachedG.drawImage(scaledImage,x,y,iw,ih,this);
      }
    }
  }
}

Fixed version (ground truth):
private void updateCachedBG(Image scaledImage){
  int width=mParent.getWidth();
  int height=mParent.getHeight();
  mCached=new BufferedImage(width,height,BufferedImage.TYPE_INT_ARGB);
  Graphics2D cachedG=mCached.createGraphics();
  if (mBottomColor != null) {
    GradientPaint p2=new GradientPaint(0,0,new Color(0,0,0,0),0,height,mBottomColor);
    cachedG.setPaint(p2);
    cachedG.fillRect(0,0,width,getHeight());
  }
  int iw=scaledImage.getWidth(null);
  int ih=scaledImage.getHeight(null);
  for (int x=0; x < width; x+=iw) {
    for (int y=0; y < height; y+=ih) {
      cachedG.drawImage(scaledImage,x,y,iw,ih,null);
    }
  }
}
Program: 80678
Project: 80678
Buggy source:
@Override public void update(Observable o,Object arg){
  SwingUtilities.invokeLater(new Runnable(){
    @Override public void run(){
      MessageView.this.updateOnEDT();
    }
  }
);
}

Fixed version (ground truth):
@Override public void update(Observable o,Object arg){
  if (SwingUtilities.isEventDispatchThread()) {
    this.updateOnEDT();
    return;
  }
  SwingUtilities.invokeLater(new Runnable(){
    @Override public void run(){
      MessageView.this.updateOnEDT();
    }
  }
);
}
Program: 80679
Project: 80679
Buggy source:
@Override public void update(Observable o,Object arg){
  SwingUtilities.invokeLater(new Runnable(){
    @Override public void run(){
      UserListView.this.updateOnEDT();
    }
  }
);
}

Fixed version (ground truth):
@Override public void update(Observable o,Object arg){
  if (SwingUtilities.isEventDispatchThread()) {
    this.updateOnEDT();
    return;
  }
  SwingUtilities.invokeLater(new Runnable(){
    @Override public void run(){
      UserListView.this.updateOnEDT();
    }
  }
);
}
Program: 80680
Project: 80680
Buggy source:
@Override public void update(Observable o,final Object arg){
  SwingUtilities.invokeLater(new Runnable(){
    @Override public void run(){
      View.this.updateOnEDT(arg);
    }
  }
);
}

Fixed version (ground truth):
@Override public void update(Observable o,final Object arg){
  if (SwingUtilities.isEventDispatchThread()) {
    this.updateOnEDT(arg);
    return;
  }
  SwingUtilities.invokeLater(new Runnable(){
    @Override public void run(){
      View.this.updateOnEDT(arg);
    }
  }
);
}
Program: 80682
Project: 80682
Buggy source:
MessageViewList(KonThread thread){
  super();
  mThread=thread;
  this.setOpaque(false);
  this.addComponentListener(new ComponentAdapter(){
    @Override public void componentResized(    ComponentEvent e){
      MessageViewList table=MessageViewList.this;
      for (int row=0; row < table.getRowCount(); row++) {
        MessageViewList.this.setHeight(row);
      }
    }
  }
);
  this.setSelectionModel(new UnselectableListModel());
  for (  KonMessage message : mThread.getMessages()) {
    this.addMessage(message);
  }
  this.addMouseListener(new MouseAdapter(){
    @Override public void mousePressed(    MouseEvent e){
      check(e);
    }
    @Override public void mouseReleased(    MouseEvent e){
      check(e);
    }
    private void check(    MouseEvent e){
      if (e.isPopupTrigger()) {
        MessageViewList.this.showPopupMenu(e);
      }
    }
  }
);
  mThread.addObserver(this);
}

Fixed version (ground truth):
MessageViewList(KonThread thread){
  super();
  mThread=thread;
  this.setOpaque(false);
  this.addComponentListener(new ComponentAdapter(){
    @Override public void componentResized(    ComponentEvent e){
      MessageViewList table=MessageViewList.this;
      for (int row=0; row < table.getRowCount(); row++) {
        MessageViewList.this.setHeight(row);
      }
      if (mScrollDownOnResize) {
        table.scrollToRow(table.getRowCount() - 1);
        mScrollDownOnResize=false;
      }
    }
  }
);
  this.setSelectionModel(new UnselectableListModel());
  for (  KonMessage message : mThread.getMessages()) {
    this.addMessage(message);
  }
  this.addMouseListener(new MouseAdapter(){
    @Override public void mousePressed(    MouseEvent e){
      check(e);
    }
    @Override public void mouseReleased(    MouseEvent e){
      check(e);
    }
    private void check(    MouseEvent e){
      if (e.isPopupTrigger()) {
        MessageViewList.this.showPopupMenu(e);
      }
    }
  }
);
  mThread.addObserver(this);
}
Program: 80683
Project: 80683
Buggy source:
@Override public void componentResized(ComponentEvent e){
  MessageViewList table=MessageViewList.this;
  for (int row=0; row < table.getRowCount(); row++) {
    MessageViewList.this.setHeight(row);
  }
}

Fixed version (ground truth):
@Override public void componentResized(ComponentEvent e){
  MessageViewList table=MessageViewList.this;
  for (int row=0; row < table.getRowCount(); row++) {
    MessageViewList.this.setHeight(row);
  }
  if (mScrollDownOnResize) {
    table.scrollToRow(table.getRowCount() - 1);
    mScrollDownOnResize=false;
  }
}
Program: 80684
Project: 80684
Buggy source:
void showThread(KonThread thread){
  boolean isNew=false;
  if (!mThreadCache.containsKey(thread.getID())) {
    mThreadCache.put(thread.getID(),new MessageViewList(thread));
    isNew=true;
  }
  MessageViewList table=mThreadCache.get(thread.getID());
  this.setViewportView(table);
  if (table.getRowCount() > 0 && isNew) {
    table.scrollToRow(table.getRowCount() - 1);
  }
  mCurrentThreadID=thread.getID();
}

Fixed version (ground truth):
void showThread(KonThread thread){
  boolean isNew=false;
  if (!mThreadCache.containsKey(thread.getID())) {
    mThreadCache.put(thread.getID(),new MessageViewList(thread));
    isNew=true;
  }
  MessageViewList table=mThreadCache.get(thread.getID());
  this.setViewportView(table);
  if (table.getRowCount() > 0 && isNew) {
    table.mScrollDownOnResize=true;
  }
  mCurrentThreadID=thread.getID();
}
Program: 80687
Project: 80687
Buggy source:
private int insert(){
  Database db=Database.getInstance();
  List<Object> values=new LinkedList<>();
  values.add(mThread.getID());
  values.add(mDir);
  values.add(mUser.getID());
  values.add(mJID);
  values.add(mXMPPID.isEmpty() ? null : mXMPPID);
  values.add(mDate);
  values.add(mReceiptStatus);
  values.add(mReceiptID.isEmpty() ? null : mReceiptID);
  values.add(mContent.toJSONString());
  values.add(mEncryption);
  values.add(mSigning);
  values.add(mCoderErrors);
synchronized (KonMessage.class) {
    if (!mReceiptID.isEmpty()) {
      if (db.execCount(TABLE,"String_Node_Str",mReceiptID) > 0) {
        LOGGER.info("String_Node_Str" + mReceiptID);
        return -1;
      }
    }
    int id=db.execInsert(TABLE,values);
    if (id <= 0)     LOGGER.log(Level.WARNING,"String_Node_Str");
    return -2;
  }
}

Fixed version (ground truth):
private int insert(){
  Database db=Database.getInstance();
  List<Object> values=new LinkedList<>();
  values.add(mThread.getID());
  values.add(mDir);
  values.add(mUser.getID());
  values.add(mJID);
  values.add(mXMPPID.isEmpty() ? null : mXMPPID);
  values.add(mDate);
  values.add(mReceiptStatus);
  values.add(mReceiptID.isEmpty() ? null : mReceiptID);
  values.add(mContent.toJSONString());
  values.add(mEncryption);
  values.add(mSigning);
  values.add(mCoderErrors);
synchronized (KonMessage.class) {
    if (!mReceiptID.isEmpty()) {
      if (db.execCount(TABLE,"String_Node_Str",mReceiptID) > 0) {
        LOGGER.info("String_Node_Str" + mReceiptID);
        return -1;
      }
    }
    int id=db.execInsert(TABLE,values);
    if (id <= 0) {
      LOGGER.log(Level.WARNING,"String_Node_Str");
      return -2;
    }
    return id;
  }
}
Program: 80688
Project: 80688
Buggy source:
/** 
 * Get the number of rows in one table that match a WHERE clause with one 'key' == 'value' condition.
 * @return number of rows for a SELECT/count query, -1 if something went wrong
 */
public int execCount(String table,String key,Object value){
  String select="String_Node_Str" + table + "String_Node_Str"+ key+ "String_Node_Str";
  try {
    PreparedStatement stat=mConn.prepareStatement(select);
    setValue(stat,0,value);
    ResultSet resultSet=stat.executeQuery();
    resultSet.last();
    return resultSet.getRow();
  }
 catch (  SQLException ex) {
    LOGGER.log(Level.WARNING,"String_Node_Str" + select,ex);
    return -1;
  }
}

Fixed version (ground truth):
/** 
 * Get the number of rows in one table that match a WHERE clause with one 'key' == 'value' condition.
 * @return number of rows for a SELECT/count query, -1 if something went wrong
 */
public int execCount(String table,String key,Object value){
  String select="String_Node_Str" + table + "String_Node_Str"+ key+ "String_Node_Str";
  try {
    PreparedStatement stat=mConn.prepareStatement(select);
    setValue(stat,0,value);
    ResultSet resultSet=stat.executeQuery();
    return resultSet.getInt(1);
  }
 catch (  SQLException ex) {
    LOGGER.log(Level.WARNING,"String_Node_Str" + select,ex);
    return -1;
  }
}
Program: 80690
Project: 80690
Buggy source:
public void changed(){
  this.setChanged();
  this.notifyObservers();
}

Fixed version (ground truth):
public synchronized void changed(){
  this.setChanged();
  this.notifyObservers();
}
Program: 80691
Project: 80691
Buggy source:
OutMessage(KonThread thread,User user,String text,boolean encrypted){
  super(thread,Direction.IN,new Date(),text,user,user.getJID(),Packet.nextID());
  mReceiptStatus=KonMessage.Status.PENDING;
  mReceiptID=null;
  if (encrypted) {
    mEncryption=Coder.Encryption.ENCRYPTED;
    mSigning=Coder.Signing.SIGNED;
  }
 else {
    mEncryption=Coder.Encryption.NOT;
    mSigning=Coder.Signing.NOT;
  }
}

Fixed version (ground truth):
OutMessage(KonThread thread,User user,String text,boolean encrypted){
  super(thread,Direction.OUT,new Date(),text,user,user.getJID(),Packet.nextID());
  mReceiptStatus=KonMessage.Status.PENDING;
  mReceiptID=null;
  if (encrypted) {
    mEncryption=Coder.Encryption.ENCRYPTED;
    mSigning=Coder.Signing.SIGNED;
  }
 else {
    mEncryption=Coder.Encryption.NOT;
    mSigning=Coder.Signing.NOT;
  }
}
Program: 80692
Project: 80692
Buggy source:
public void connect(){
  Account account=Account.getInstance();
  try {
    account.reload();
  }
 catch (  KonException ex) {
    this.handleException(ex);
    return;
  }
  List args=new ArrayList(1);
  args.add(account.getPersonalKey());
  Client.TASK_QUEUE.offer(new Client.Task(Client.Command.CONNECT,args));
}

Fixed version (ground truth):
public void connect(){
  Account account=Account.getInstance();
  try {
    account.reload();
  }
 catch (  KonException ex) {
    this.handleException(ex);
    return;
  }
  mClient.connect(account.getPersonalKey());
}
Program: 80693
Project: 80693
Buggy source:
public Task(Command c,List a){
  command=c;
  args=a;
}

Fixed version (ground truth):
Task(Command c,List a){
  command=c;
  args=a;
}
Program: 80694
Project: 80694
Buggy source:
@Override public void run(){
  while (true) {
    Task t;
    try {
      t=TASK_QUEUE.take();
    }
 catch (    InterruptedException ex) {
      LOGGER.log(Level.WARNING,"String_Node_Str",ex);
      return;
    }
switch (t.command) {
case CONNECT:
      this.connect((PersonalKey)t.args.get(0));
    break;
case DISCONNECT:
  this.disconnect();
break;
}
}
}

Fixed version (ground truth):
@Override public void run(){
  while (true) {
    Task t;
    try {
      t=TASK_QUEUE.take();
    }
 catch (    InterruptedException ex) {
      LOGGER.log(Level.WARNING,"String_Node_Str",ex);
      return;
    }
switch (t.command) {
case CONNECT:
      this.connectAsync();
    break;
case DISCONNECT:
  this.disconnect();
break;
}
}
}
Program: 80696
Project: 80696
Buggy source:
private void update(){
switch (mMessage.getStatus()) {
case PENDING:
    mStatusIconLabel.setIcon(PENDING_ICON);
  break;
case SENT:
mStatusIconLabel.setIcon(SENT_ICON);
break;
case RECEIVED:
mStatusIconLabel.setIcon(DELIVERED_ICON);
break;
}
doRepaint();
}

Fixed version (ground truth):
private void update(){
switch (mMessage.getStatus()) {
case PENDING:
    mStatusIconLabel.setIcon(PENDING_ICON);
  break;
case SENT:
mStatusIconLabel.setIcon(SENT_ICON);
break;
case RECEIVED:
mStatusIconLabel.setIcon(DELIVERED_ICON);
break;
}
}
Program: 80697
Project: 80697
Buggy source:
MessageViewList(KonThread thread){
  mThread=thread;
  mThread.addListener(this);
  this.setOpaque(false);
  this.setModel(mListModel);
  this.setCellRenderer(new MessageListRenderer());
  this.setSelectionModel(new DefaultListSelectionModel(){
    @Override public void setSelectionInterval(    int index0,    int index1){
    }
    @Override public void addSelectionInterval(    int index0,    int index1){
    }
  }
);
}

Fixed version (ground truth):
MessageViewList(KonThread thread){
  mThread=thread;
  mThread.addListener(this);
  this.setOpaque(false);
  this.setModel(mListModel);
  this.setCellRenderer(new MessageListRenderer());
  this.addComponentListener(new ComponentAdapter(){
    @Override public void componentResized(    ComponentEvent e){
      recache();
    }
  }
);
  this.setSelectionModel(new DefaultListSelectionModel(){
    @Override public void setSelectionInterval(    int index0,    int index1){
    }
    @Override public void addSelectionInterval(    int index0,    int index1){
    }
  }
);
  this.update();
  if (!mListModel.isEmpty())   this.ensureIndexIsVisible(mListModel.getSize() - 1);
}
Program: 80699
Project: 80699
Buggy source:
private void resize(int listWidth){
  int maxWidth=(int)(listWidth * 0.8);
  int width=Math.min(mPreferredTextAreaWidth,maxWidth);
  mTextArea.setSize(width,Short.MAX_VALUE);
}

Fixed version (ground truth):
private void resize(int listWidth){
  int maxWidth=(int)(listWidth * 0.8);
  int width=Math.min(mPreferredTextAreaWidth,maxWidth);
  mTextArea.setSize(width,mTextArea.getPreferredSize().height);
}
Program: 80700
Project: 80700
Buggy source:
@Override public void stateChanged(ChangeEvent e){
  update();
}

Fixed version (ground truth):
@Override public void stateChanged(ChangeEvent e){
  update();
  doRepaint();
}
Program: 80701
Project: 80701
Buggy source:
void showThread(KonThread thread){
  if (thread == null)   return;
  if (!mThreadCache.containsKey(thread.getID())) {
    mThreadCache.put(thread.getID(),new MessageViewList(thread));
  }
  MessageViewList list=mThreadCache.get(thread.getID());
  this.setViewportView(list);
  list.update();
  list.update();
  mCurrentThreadID=thread.getID();
}

Fixed version (ground truth):
void showThread(KonThread thread){
  if (!mThreadCache.containsKey(thread.getID())) {
    mThreadCache.put(thread.getID(),new MessageViewList(thread));
  }
  MessageViewList list=mThreadCache.get(thread.getID());
  this.setViewportView(list);
  mCurrentThreadID=thread.getID();
}
Program: 80702
Project: 80702
Buggy source:
void selectThreadByUser(User user){
  if (user == null) {
    mThreadView.showThread(null);
  }
 else {
    KonThread thread=ThreadList.getInstance().getThreadByUser(user);
    mThreadListView.selectThread(thread.getID());
    mMainFrame.selectTab(MainFrame.Tab.THREADS);
    mThreadView.showThread(thread);
  }
}

Fixed version (ground truth):
void selectThreadByUser(User user){
  if (user == null)   return;
  KonThread thread=ThreadList.getInstance().getThreadByUser(user);
  mThreadListView.selectThread(thread.getID());
  mMainFrame.selectTab(MainFrame.Tab.THREADS);
  mThreadView.showThread(thread);
}
Program: 80703
Project: 80703
Buggy source:
private static boolean containsAnyJavaType(TypeInfo type){
  if (type instanceof ParameterizedTypeInfo) {
    return ((ParameterizedTypeInfo)type).getArgs().stream().anyMatch(MethodInfo::containsAnyJavaType);
  }
 else {
    return type.getKind() == ClassKind.OTHER;
  }
}

Fixed version (ground truth):
private static boolean containsAnyJavaType(TypeInfo type){
  if (type instanceof ParameterizedTypeInfo) {
    return containsAnyJavaType(type.getRaw()) || ((ParameterizedTypeInfo)type).getArgs().stream().anyMatch(MethodInfo::containsAnyJavaType);
  }
 else {
    return type.getKind() == ClassKind.OTHER;
  }
}
Program: 80705
Project: 80705
Buggy source:
private static <T>List<T> fromArray(JsonObject obj,String name,Function<Object,T> converter){
  JsonArray array=obj.getJsonArray(name);
  if (array != null) {
    List<?> list=array.getList();
    return list.stream().map(converter).collect(Collectors.toList());
  }
 else {
    return null;
  }
}

Fixed version (ground truth):
private static <T>List<T> fromArray(JsonObject obj,String name,Function<Object,T> converter){
  JsonArray array=obj.getJsonArray(name);
  if (array != null) {
    return array.stream().map(converter).collect(Collectors.toList());
  }
 else {
    return null;
  }
}
Program: 80706
Project: 80706
Buggy source:
private static <T>Map<String,T> fromObject(JsonObject obj,String name,Function<Object,T> converter){
  JsonObject array=obj.getJsonObject(name);
  if (array != null) {
    Map<String,Object> map=array.getMap();
    map.entrySet().forEach(entry -> entry.setValue(converter.apply(entry.getValue())));
    return (Map<String,T>)map;
  }
 else {
    return null;
  }
}

Fixed version (ground truth):
private static <T>Map<String,T> fromObject(JsonObject obj,String name,Function<Object,T> converter){
  JsonObject array=obj.getJsonObject(name);
  if (array != null) {
    return array.stream().collect(Collectors.toMap(entry -> entry.getKey(),entry -> converter.apply(entry.getValue())));
  }
 else {
    return null;
  }
}
Program: 80707
Project: 80707
Buggy source:
public DataObjectWithLists(JsonObject json){
  booleanValues=fromArray(json,"String_Node_Str");
  shortValues=fromArray(json,"String_Node_Str",o -> Short.parseShort(o.toString()));
  integerValues=fromArray(json,"String_Node_Str");
  longValues=fromArray(json,"String_Node_Str",o -> Long.parseLong(o.toString()));
  floatValues=fromArray(json,"String_Node_Str",o -> Float.parseFloat(o.toString()));
  doubleValues=fromArray(json,"String_Node_Str");
  stringValues=fromArray(json,"String_Node_Str");
  jsonObjectValues=fromArray(json,"String_Node_Str",o -> new JsonObject((Map<String,Object>)o));
  jsonArrayValues=fromArray(json,"String_Node_Str",o -> new JsonArray((List)o));
  dataObjectValues=fromArray(json,"String_Node_Str",o -> new TestDataObject(new JsonObject((Map<String,Object>)o)));
  enumValues=fromArray(json,"String_Node_Str",o -> TestEnum.valueOf(o.toString()));
  genEnumValues=fromArray(json,"String_Node_Str",o -> TestGenEnum.valueOf(o.toString()));
}

Fixed version (ground truth):
public DataObjectWithLists(JsonObject json){
  booleanValues=fromArray(json,"String_Node_Str");
  shortValues=fromArray(json,"String_Node_Str",o -> Short.parseShort(o.toString()));
  integerValues=fromArray(json,"String_Node_Str");
  longValues=fromArray(json,"String_Node_Str",o -> Long.parseLong(o.toString()));
  floatValues=fromArray(json,"String_Node_Str",o -> Float.parseFloat(o.toString()));
  doubleValues=fromArray(json,"String_Node_Str");
  stringValues=fromArray(json,"String_Node_Str");
  jsonObjectValues=fromArray(json,"String_Node_Str",o -> (JsonObject)o);
  jsonArrayValues=fromArray(json,"String_Node_Str",o -> (JsonArray)o);
  dataObjectValues=fromArray(json,"String_Node_Str",o -> new TestDataObject((JsonObject)o));
  enumValues=fromArray(json,"String_Node_Str",o -> TestEnum.valueOf(o.toString()));
  genEnumValues=fromArray(json,"String_Node_Str",o -> TestGenEnum.valueOf(o.toString()));
}
Program: 80708
Project: 80708
Buggy source:
public DataObjectWithMaps(JsonObject json){
  booleanValues=fromObject(json,"String_Node_Str");
  shortValues=fromObject(json,"String_Node_Str",o -> Short.parseShort(o.toString()));
  integerValues=fromObject(json,"String_Node_Str");
  longValues=fromObject(json,"String_Node_Str",o -> Long.parseLong(o.toString()));
  floatValues=fromObject(json,"String_Node_Str",o -> Float.parseFloat(o.toString()));
  doubleValues=fromObject(json,"String_Node_Str");
  stringValues=fromObject(json,"String_Node_Str");
  jsonObjectValues=fromObject(json,"String_Node_Str",o -> new JsonObject((Map<String,Object>)o));
  jsonArrayValues=fromObject(json,"String_Node_Str",o -> new JsonArray((List)o));
  dataObjectValues=fromObject(json,"String_Node_Str",o -> new TestDataObject(new JsonObject((Map<String,Object>)o)));
  enumValues=fromObject(json,"String_Node_Str",o -> TestEnum.valueOf(o.toString()));
  genEnumValues=fromObject(json,"String_Node_Str",o -> TestGenEnum.valueOf(o.toString()));
}

Fixed version (ground truth):
public DataObjectWithMaps(JsonObject json){
  booleanValues=fromObject(json,"String_Node_Str");
  shortValues=fromObject(json,"String_Node_Str",o -> Short.parseShort(o.toString()));
  integerValues=fromObject(json,"String_Node_Str");
  longValues=fromObject(json,"String_Node_Str",o -> Long.parseLong(o.toString()));
  floatValues=fromObject(json,"String_Node_Str",o -> Float.parseFloat(o.toString()));
  doubleValues=fromObject(json,"String_Node_Str");
  stringValues=fromObject(json,"String_Node_Str");
  jsonObjectValues=fromObject(json,"String_Node_Str",o -> (JsonObject)o);
  jsonArrayValues=fromObject(json,"String_Node_Str",o -> (JsonArray)o);
  dataObjectValues=fromObject(json,"String_Node_Str",o -> new TestDataObject((JsonObject)o));
  enumValues=fromObject(json,"String_Node_Str",o -> TestEnum.valueOf(o.toString()));
  genEnumValues=fromObject(json,"String_Node_Str",o -> TestGenEnum.valueOf(o.toString()));
}
Program: 80709
Project: 80709
Buggy source:
public TypeArgExpression resolveTypeArg(TypeVariableInfo typeVar){
  for (  TypeParamInfo.Method typeParam : typeParams) {
    if (typeParam.getName().equals(typeVar.getName())) {
      for (      ParamInfo param : params) {
        if (param.getType().getKind() == ClassKind.CLASS_TYPE && param.getType().isParameterized()) {
          TypeInfo arg_=((ParameterizedTypeInfo)param.getType()).getArg(0);
          if (arg_.isVariable()) {
            TypeVariableInfo ttt=(TypeVariableInfo)arg_;
            if (ttt.getParam().equals(typeParam)) {
              return new TypeArgExpression(TypeArgExpression.CLASS_TYPE_ARG,ttt,param,0);
            }
          }
        }
 else         if (param.getType().getKind() == ClassKind.API && param.getType().isParameterized()) {
          ParameterizedTypeInfo type=(ParameterizedTypeInfo)param.getType();
          int index=0;
          for (          TypeInfo i : type.getArgs()) {
            if (i instanceof TypeVariableInfo) {
              TypeVariableInfo tt=(TypeVariableInfo)i;
              if (tt.isClassParam() && tt.getParam().equals(typeParam)) {
                return new TypeArgExpression(TypeArgExpression.CLASS_TYPE_ARG,tt,param,index);
              }
            }
            index++;
          }
        }
      }
      return null;
    }
  }
  return null;
}

Fixed version (ground truth):
public TypeArgExpression resolveTypeArg(TypeVariableInfo typeVar){
  for (  TypeParamInfo.Method typeParam : typeParams) {
    if (typeParam.getName().equals(typeVar.getName())) {
      for (      ParamInfo param : params) {
        if (param.getType().getKind() == ClassKind.CLASS_TYPE && param.getType().isParameterized()) {
          TypeInfo arg_=((ParameterizedTypeInfo)param.getType()).getArg(0);
          if (arg_.isVariable()) {
            TypeVariableInfo ttt=(TypeVariableInfo)arg_;
            if (ttt.getParam().equals(typeParam)) {
              return new TypeArgExpression(TypeArgExpression.CLASS_TYPE_ARG,ttt,param,0);
            }
          }
        }
 else         if (param.getType().getKind() == ClassKind.API && param.getType().isParameterized()) {
          ParameterizedTypeInfo type=(ParameterizedTypeInfo)param.getType();
          int index=0;
          for (          TypeInfo i : type.getArgs()) {
            if (i instanceof TypeVariableInfo) {
              TypeVariableInfo tt=(TypeVariableInfo)i;
              if (tt.getParam().equals(typeParam)) {
                return new TypeArgExpression(TypeArgExpression.API_ARG,tt,param,index);
              }
            }
            index++;
          }
        }
      }
      return null;
    }
  }
  return null;
}
Program: 80710
Project: 80710
Buggy source:
/** 
 * Load a template given its   {@code source}.
 * @param source the template source
 * @return the compiled template
 */
public static CompiledTemplate loadCompiled(InputStream source){
  String template;
  try (Scanner scanner=new Scanner(source,"String_Node_Str").useDelimiter("String_Node_Str")){
    template=scanner.next();
  }
   template=template.replace("String_Node_Str","String_Node_Str").replace("String_Node_Str","String_Node_Str").replace("String_Node_Str","String_Node_Str");
  ClassLoader currentCL=Thread.currentThread().getContextClassLoader();
  Thread.currentThread().setContextClassLoader(TemplateRuntime.class.getClassLoader());
  try {
    return TemplateCompiler.compileTemplate(template);
  }
  finally {
    Thread.currentThread().setContextClassLoader(currentCL);
  }
}

Fixed version (ground truth):
/** 
 * Load a template given its   {@code source}.
 * @param source the template source
 * @return the compiled template
 */
public static CompiledTemplate loadCompiled(InputStream source){
  String template;
  try (Scanner scanner=new Scanner(source,"String_Node_Str").useDelimiter("String_Node_Str")){
    template=scanner.next();
  }
   template=template.replace("String_Node_Str","String_Node_Str").replace("String_Node_Str","String_Node_Str").replace("String_Node_Str",System.getProperty("String_Node_Str")).replace("String_Node_Str","String_Node_Str");
  ClassLoader currentCL=Thread.currentThread().getContextClassLoader();
  Thread.currentThread().setContextClassLoader(TemplateRuntime.class.getClassLoader());
  try {
    return TemplateCompiler.compileTemplate(template);
  }
  finally {
    Thread.currentThread().setContextClassLoader(currentCL);
  }
}
Program: 80711
Project: 80711
Buggy source:
@Override public String format(Iterable<String> atoms){
  StringBuilder sb=new StringBuilder();
  Iterator<String> it=atoms.iterator();
  while (it.hasNext()) {
    String atom=it.next();
    if (atom.length() > 0) {
      sb.append(atom.toLowerCase());
      break;
    }
  }
  while (it.hasNext()) {
    String atom=it.next();
    if (atom.length() > 0) {
      char c=atom.charAt(0);
      if (Character.isLowerCase(c)) {
        sb.append(Character.toUpperCase(c));
        sb.append(atom,1,atom.length());
      }
 else {
        sb.append(atom);
      }
      break;
    }
  }
  return sb.toString();
}

Fixed version (ground truth):
@Override public String format(Iterable<String> atoms){
  StringBuilder sb=new StringBuilder();
  Iterator<String> it=atoms.iterator();
  while (it.hasNext()) {
    String atom=it.next();
    if (atom.length() > 0) {
      sb.append(atom.toLowerCase());
      break;
    }
  }
  while (it.hasNext()) {
    String atom=it.next();
    if (atom.length() > 0) {
      char c=atom.charAt(0);
      if (Character.isLowerCase(c)) {
        sb.append(Character.toUpperCase(c));
        sb.append(atom,1,atom.length());
      }
 else {
        sb.append(atom);
      }
    }
  }
  return sb.toString();
}
Program: 80712
Project: 80712
Buggy source:
@Test public void testFormatLowerCamelCase(){
  formatLowerCamelCase("String_Node_Str","String_Node_Str");
  formatLowerCamelCase("String_Node_Str","String_Node_Str");
  formatLowerCamelCase("String_Node_Str","String_Node_Str");
  formatLowerCamelCase("String_Node_Str","String_Node_Str");
  formatLowerCamelCase("String_Node_Str","String_Node_Str","String_Node_Str");
  formatLowerCamelCase("String_Node_Str","String_Node_Str","String_Node_Str");
  formatLowerCamelCase("String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str");
  formatLowerCamelCase("String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str");
}

Fixed version (ground truth):
@Test public void testFormatLowerCamelCase(){
  formatLowerCamelCase("String_Node_Str","String_Node_Str");
  formatLowerCamelCase("String_Node_Str","String_Node_Str");
  formatLowerCamelCase("String_Node_Str","String_Node_Str");
  formatLowerCamelCase("String_Node_Str","String_Node_Str");
  formatLowerCamelCase("String_Node_Str","String_Node_Str","String_Node_Str");
  formatLowerCamelCase("String_Node_Str","String_Node_Str","String_Node_Str");
  formatLowerCamelCase("String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str");
  formatLowerCamelCase("String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str");
  formatLowerCamelCase("String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str");
}
Program: 80714
Project: 80714
Buggy source:
public void apply(Model model,File outputFile) throws Exception {
  String output=render(model,new HashMap<>());
  if (!outputFile.getParentFile().exists()) {
    outputFile.getParentFile().mkdirs();
  }
  try (PrintStream outStream=new PrintStream(new FileOutputStream(outputFile))){
    outStream.print(output);
    outStream.flush();
  }
 }

Fixed version (ground truth):
public void apply(Model model,File outputFile) throws Exception {
  String output=render(model,new HashMap<>());
  Helper.ensureParentDir(outputFile);
  try (PrintStream outStream=new PrintStream(new FileOutputStream(outputFile))){
    outStream.print(output);
    outStream.flush();
  }
 }
Program: 80716
Project: 80716
Buggy source:
@Test public void testUncommentedPropertyOverridesCommentedProperty() throws Exception {
  DataObjectModel model=new Generator().generateDataObject(UncommentedPropertyOverridesCommentedProperty.class,AbstractCommentedProperty.class);
  PropertyInfo propertyInfo=model.getPropertyMap().get("String_Node_Str");
  Doc propertyDoc=propertyInfo.getDoc();
  assertEquals("String_Node_Str",propertyDoc.getFirstSentence().getValue());
}

Fixed version (ground truth):
@Test public void testUncommentedPropertyOverridesCommentedProperty() throws Exception {
  DataObjectModel model=new Generator().generateDataObject(UncommentedPropertyOverridesSuperCommentedProperty.class,AbstractCommentedProperty.class);
  PropertyInfo propertyInfo=model.getPropertyMap().get("String_Node_Str");
  Doc propertyDoc=propertyInfo.getDoc();
  assertEquals("String_Node_Str",propertyDoc.getFirstSentence().getValue());
}
Program: 80717
Project: 80717
Buggy source:
TestInterface method();

Fixed version (ground truth):
static TestInterface method(){
  return new TestInterfaceImpl();
}
Program: 80718
Project: 80718
Buggy source:
Window findTargetWindow(Window window,LayoutElement layout);

Fixed version (ground truth):
@Nullable Window findTargetWindow(Window window,LayoutElement layout);
Program: 80719
Project: 80719
Buggy source:
private static Window currentWindowIn(LayoutElement windowLayout){
  return find(Directions.allWindowsIn(windowLayout),new Condition<Window>(){
    @Override public boolean value(    Window window){
      return window.isCurrent;
    }
  }
);
}

Fixed version (ground truth):
@Nullable private static Window currentWindowIn(LayoutElement windowLayout){
  return find(Directions.allWindowsIn(windowLayout),new Condition<Window>(){
    @Override public boolean value(    Window window){
      return window.isCurrent;
    }
  }
);
}
Program: 80720
Project: 80720
Buggy source:
public void moveFocus(Directions.Direction direction){
  LayoutElement layout=calculateAndSetPositions(ide.snapshotWindowLayout());
  if (layout == LayoutElement.none)   return;
  Window window=currentWindowIn(layout);
  Window targetWindow=direction.findTargetWindow(window,layout);
  ide.setFocusOn(targetWindow);
}

Fixed version (ground truth):
public void moveFocus(Directions.Direction direction){
  LayoutElement layout=calculateAndSetPositions(ide.snapshotWindowLayout());
  if (layout == LayoutElement.none)   return;
  Window window=currentWindowIn(layout);
  if (window == null)   return;
  Window targetWindow=direction.findTargetWindow(window,layout);
  if (targetWindow == null)   return;
  ide.setFocusOn(targetWindow);
}
Program: 80722
Project: 80722
Buggy source:
private static Window findWindowBy(final Position position,LayoutElement layout){
  return find(Directions.allWindowsIn(layout),new Condition<Window>(){
    @Override public boolean value(    Window window){
      return position.equals(window.position);
    }
  }
);
}

Fixed version (ground truth):
@Nullable private static Window findWindowBy(final Position position,LayoutElement layout){
  return find(Directions.allWindowsIn(layout),new Condition<Window>(){
    @Override public boolean value(    Window window){
      return position.equals(window.position);
    }
  }
);
}
Program: 80723
Project: 80723
Buggy source:
@Override public String getUrl(){
  if (this.getParameters != null && !this.getParameters.isEmpty()) {
    Uri.Builder builder=Uri.parse(super.getUrl()).buildUpon();
    for (    Map.Entry<String,Object> entry : this.getParameters.entrySet()) {
      Object entryValue=entry.getValue();
      String entryKey=entry.getKey();
      if (entryValue == null) {
        builder.appendQueryParameter(entryKey,null);
        break;
      }
      if (entryValue instanceof Collection) {
        Collection items=(Collection)entryValue;
        for (        Object item : items) {
          if (item == null) {
            builder.appendQueryParameter(entryKey,null);
          }
 else {
            builder.appendQueryParameter(entryKey,entryValue.toString());
          }
        }
      }
 else {
        builder.appendQueryParameter(entryKey,entryValue.toString());
      }
    }
    String urlString=builder.build().toString();
    return urlString;
  }
 else {
    return super.getUrl();
  }
}

Fixed version (ground truth):
@Override public String getUrl(){
  if (this.getParameters != null && !this.getParameters.isEmpty()) {
    Uri.Builder builder=Uri.parse(super.getUrl()).buildUpon();
    for (    Map.Entry<String,Object> entry : this.getParameters.entrySet()) {
      Object entryValue=entry.getValue();
      String entryKey=entry.getKey();
      if (entryValue == null) {
        builder.appendQueryParameter(entryKey,null);
        break;
      }
      if (entryValue instanceof Collection) {
        Collection items=(Collection)entryValue;
        for (        Object item : items) {
          if (item == null) {
            builder.appendQueryParameter(entryKey,null);
          }
 else {
            builder.appendQueryParameter(entryKey,item.toString());
          }
        }
      }
 else {
        builder.appendQueryParameter(entryKey,entryValue.toString());
      }
    }
    String urlString=builder.build().toString();
    return urlString;
  }
 else {
    return super.getUrl();
  }
}
Program: 80724
Project: 80724
Buggy source:
@Override protected VolleyError parseNetworkError(VolleyError volleyError){
  VolleyError error=super.parseNetworkError(volleyError);
  this.result=new ResponseData();
  if (volleyError.networkResponse != null) {
    this.result.headers=new HashMap<String,String>(volleyError.networkResponse.headers);
    this.result.statusCode=volleyError.networkResponse.statusCode;
    if (this.errorResponseClasSpecifier != null) {
      Response<ResponseData> result=this.responseHandler.parseNetworkResponse(volleyError.networkResponse,responseClasSpecifier);
      this.result.parsedErrorResponse=result.result;
    }
  }
  this.result.error=error;
  return error;
}

Fixed version (ground truth):
@Override protected VolleyError parseNetworkError(VolleyError volleyError){
  VolleyError error=super.parseNetworkError(volleyError);
  this.result=new ResponseData();
  if (volleyError.networkResponse != null) {
    this.result.headers=new HashMap<String,String>(volleyError.networkResponse.headers);
    this.result.statusCode=volleyError.networkResponse.statusCode;
    if (this.errorResponseClasSpecifier != null) {
      Response<ResponseData> result=this.responseHandler.parseNetworkResponse(volleyError.networkResponse,errorResponseClasSpecifier);
      this.result.parsedErrorResponse=result.result;
    }
  }
  this.result.error=error;
  return error;
}