Program: 103421
Project: 103421
Buggy source:
/** 
 * Returns this panel that has been configured to display the meta contact and meta contact group cells.
 * @param tree the source tree
 * @param value the tree node
 * @param selected indicates if the node is selected
 * @param expanded indicates if the node is expanded
 * @param leaf indicates if the node is a leaf
 * @param row indicates the row number of the node
 * @param hasFocus indicates if the node has the focus
 * @return this panel
 */
public Component getTreeCellRendererComponent(JTree tree,Object value,boolean selected,boolean expanded,boolean leaf,int row,boolean hasFocus){
  this.tree=tree;
  this.row=row;
  this.isSelected=selected;
  this.treeNode=(TreeNode)value;
  this.rightLabel.setIcon(null);
  DefaultTreeContactList contactList=(DefaultTreeContactList)tree;
  if (contactList instanceof TreeContactList) {
    ContactListFilter filter=((TreeContactList)contactList).getCurrentFilter();
    if (filter != null && filter.equals(TreeContactList.historyFilter) && value instanceof ContactNode && row % 2 == 0) {
      setBackground(Constants.CALL_HISTORY_EVEN_ROW_COLOR);
    }
 else {
      setBackground(Color.WHITE);
    }
  }
  if (value instanceof ContactNode) {
    UIContact contact=((ContactNode)value).getContactDescriptor();
    String displayName=contact.getDisplayName();
    if ((displayName == null || displayName.trim().length() < 1) && !(contact instanceof ShowMoreContact)) {
      displayName=GuiActivator.getResources().getI18NString("String_Node_Str");
    }
    this.nameLabel.setText(displayName);
    if (contactList.isContactActive(contact))     statusIcon.setImage(msgReceivedImage);
 else     statusIcon=contact.getStatusIcon();
    this.statusLabel.setIcon(statusIcon);
    this.nameLabel.setFont(this.getFont().deriveFont(Font.PLAIN));
    if (contactForegroundColor != null)     nameLabel.setForeground(contactForegroundColor);
    if (contact instanceof ShowMoreContact) {
      rightLabel.setFont(rightLabel.getFont().deriveFont(12f));
      rightLabel.setForeground(Color.GRAY);
      rightLabel.setText((String)contact.getDescriptor());
    }
 else     rightLabel.setText("String_Node_Str");
    this.initDisplayDetails(contact);
    this.initButtonsPanel(contact);
    int avatarWidth, avatarHeight;
    if (isSelected) {
      avatarWidth=EXTENDED_AVATAR_WIDTH;
      avatarHeight=EXTENDED_AVATAR_HEIGHT;
    }
 else {
      avatarWidth=AVATAR_WIDTH;
      avatarHeight=AVATAR_HEIGHT;
    }
    ImageIcon avatar=contact.getAvatar(isSelected,avatarWidth,avatarHeight);
    if (avatar != null) {
      this.rightLabel.setIcon(avatar);
    }
    this.setToolTipText(contact.getDescriptor().toString());
  }
 else   if (value instanceof GroupNode) {
    UIGroup groupItem=((GroupNode)value).getGroupDescriptor();
    this.nameLabel.setText(groupItem.getDisplayName());
    this.nameLabel.setFont(this.getFont().deriveFont(Font.BOLD));
    if (groupForegroundColor != null)     this.nameLabel.setForeground(groupForegroundColor);
    this.remove(displayDetailsLabel);
    this.remove(callButton);
    this.remove(callVideoButton);
    this.remove(desktopSharingButton);
    this.remove(chatButton);
    this.remove(addContactButton);
    this.statusLabel.setIcon(expanded ? openedGroupIcon : closedGroupIcon);
    this.rightLabel.setIcon(null);
    this.rightLabel.setText("String_Node_Str");
    if (groupItem.countChildContacts() >= 0) {
      rightLabel.setFont(rightLabel.getFont().deriveFont(9f));
      this.rightLabel.setForeground(Color.BLACK);
      this.rightLabel.setText(groupItem.countOnlineChildContacts() + "String_Node_Str" + groupItem.countChildContacts());
    }
    this.setToolTipText(groupItem.getDescriptor().toString());
  }
  return this;
}

Fixed version (ground truth):
/** 
 * Returns this panel that has been configured to display the meta contact and meta contact group cells.
 * @param tree the source tree
 * @param value the tree node
 * @param selected indicates if the node is selected
 * @param expanded indicates if the node is expanded
 * @param leaf indicates if the node is a leaf
 * @param row indicates the row number of the node
 * @param hasFocus indicates if the node has the focus
 * @return this panel
 */
public Component getTreeCellRendererComponent(JTree tree,Object value,boolean selected,boolean expanded,boolean leaf,int row,boolean hasFocus){
  this.tree=tree;
  this.row=row;
  this.isSelected=selected;
  this.treeNode=(TreeNode)value;
  this.rightLabel.setIcon(null);
  DefaultTreeContactList contactList=(DefaultTreeContactList)tree;
  if (contactList instanceof TreeContactList) {
    ContactListFilter filter=((TreeContactList)contactList).getCurrentFilter();
    if (filter != null && filter.equals(TreeContactList.historyFilter) && value instanceof ContactNode && row % 2 == 0) {
      setBackground(Constants.CALL_HISTORY_EVEN_ROW_COLOR);
    }
 else {
      setBackground(Color.WHITE);
    }
  }
  if (value instanceof ContactNode) {
    UIContact contact=((ContactNode)value).getContactDescriptor();
    String displayName=contact.getDisplayName();
    if ((displayName == null || displayName.trim().length() < 1) && !(contact instanceof ShowMoreContact)) {
      displayName=GuiActivator.getResources().getI18NString("String_Node_Str");
    }
    this.nameLabel.setText(displayName);
    if (contactList.isContactActive(contact))     statusIcon.setImage(msgReceivedImage);
 else     statusIcon=contact.getStatusIcon();
    this.statusLabel.setIcon(statusIcon);
    this.nameLabel.setFont(this.getFont().deriveFont(Font.PLAIN));
    if (contactForegroundColor != null)     nameLabel.setForeground(contactForegroundColor);
    this.initDisplayDetails(contact);
    this.initButtonsPanel(contact);
    int avatarWidth, avatarHeight;
    if (isSelected) {
      avatarWidth=EXTENDED_AVATAR_WIDTH;
      avatarHeight=EXTENDED_AVATAR_HEIGHT;
    }
 else {
      avatarWidth=AVATAR_WIDTH;
      avatarHeight=AVATAR_HEIGHT;
    }
    ImageIcon avatar=contact.getAvatar(isSelected,avatarWidth,avatarHeight);
    if (avatar != null) {
      this.rightLabel.setIcon(avatar);
    }
    if (contact instanceof ShowMoreContact) {
      rightLabel.setFont(rightLabel.getFont().deriveFont(12f));
      rightLabel.setForeground(Color.GRAY);
      rightLabel.setText((String)contact.getDescriptor());
    }
 else {
      rightLabel.setFont(rightLabel.getFont().deriveFont(9f));
      rightLabel.setText("String_Node_Str");
    }
    this.setToolTipText(contact.getDescriptor().toString());
  }
 else   if (value instanceof GroupNode) {
    UIGroup groupItem=((GroupNode)value).getGroupDescriptor();
    this.nameLabel.setText(groupItem.getDisplayName());
    this.nameLabel.setFont(this.getFont().deriveFont(Font.BOLD));
    if (groupForegroundColor != null)     this.nameLabel.setForeground(groupForegroundColor);
    this.remove(displayDetailsLabel);
    this.remove(callButton);
    this.remove(callVideoButton);
    this.remove(desktopSharingButton);
    this.remove(chatButton);
    this.remove(addContactButton);
    this.statusLabel.setIcon(expanded ? openedGroupIcon : closedGroupIcon);
    this.rightLabel.setIcon(null);
    this.rightLabel.setText("String_Node_Str");
    if (groupItem.countChildContacts() >= 0) {
      rightLabel.setFont(rightLabel.getFont().deriveFont(9f));
      this.rightLabel.setForeground(Color.BLACK);
      this.rightLabel.setText(groupItem.countOnlineChildContacts() + "String_Node_Str" + groupItem.countChildContacts());
    }
    this.setToolTipText(groupItem.getDescriptor().toString());
  }
  return this;
}