Program: 103017
Project: 103017
Buggy source:
/** 
 * Initializes a new <tt>PresenceStatusMenu</tt> instance which is to depict and change the presence status of a specific <tt>ProtocolProviderService</tt>.
 * @param protocolProvider the <tt>ProtocolProviderService</tt> which is tohave its presence status depicted and changed by the new instance
 */
public PresenceStatusMenu(ProtocolProviderService protocolProvider){
  super(protocolProvider.getAccountID().getDisplayName(),ImageLoader.getAccountStatusImage(protocolProvider),protocolProvider);
  this.presence=protocolProvider.getOperationSet(OperationSetPresence.class);
  Iterator<PresenceStatus> statusIterator=this.presence.getSupportedStatusSet();
  String tooltip="String_Node_Str" + protocolProvider.getAccountID().getDisplayName() + "String_Node_Str";
  this.setToolTipText(tooltip);
  titleArea=new JEditorPane();
  titleArea.setContentType("String_Node_Str");
  Constants.loadSimpleStyle(((HTMLDocument)titleArea.getDocument()).getStyleSheet(),titleArea.getFont());
  titleArea.setBorder(BorderFactory.createEmptyBorder(0,5,0,0));
  titleArea.setOpaque(false);
  titleArea.setEditable(false);
  titleArea.setAlignmentX(Component.RIGHT_ALIGNMENT);
  statusMessageMenu=new StatusMessageMenu(protocolProvider,true);
  statusMessageMenu.addPropertyChangeListener(this);
  updateTitleArea();
  this.add(titleArea);
  this.addSeparator();
  while (statusIterator.hasNext()) {
    PresenceStatus status=statusIterator.next();
    this.addItem(status.getStatusName(),new ImageIcon(status.getStatusIcon()),this);
  }
  this.addSeparator();
  this.add((JMenu)statusMessageMenu.getMenu());
  this.setSelectedStatus(getOfflineStatus());
  updateStatus(getOfflineStatus());
}

Fixed version (ground truth):
/** 
 * Initializes a new <tt>PresenceStatusMenu</tt> instance which is to depict and change the presence status of a specific <tt>ProtocolProviderService</tt>.
 * @param protocolProvider the <tt>ProtocolProviderService</tt> which is tohave its presence status depicted and changed by the new instance
 */
public PresenceStatusMenu(ProtocolProviderService protocolProvider){
  super(protocolProvider.getAccountID().getDisplayName(),ImageLoader.getAccountStatusImage(protocolProvider),protocolProvider);
  this.presence=protocolProvider.getOperationSet(OperationSetPresence.class);
  Iterator<PresenceStatus> statusIterator=this.presence.getSupportedStatusSet();
  String tooltip="String_Node_Str" + protocolProvider.getAccountID().getDisplayName() + "String_Node_Str";
  this.setToolTipText(tooltip);
  titleArea=new JEditorPane();
  titleArea.setContentType("String_Node_Str");
  Constants.loadSimpleStyle(((HTMLDocument)titleArea.getDocument()).getStyleSheet(),titleArea.getFont());
  titleArea.setBorder(BorderFactory.createEmptyBorder(0,5,0,0));
  titleArea.setOpaque(false);
  titleArea.setEditable(false);
  titleArea.setAlignmentX(Component.RIGHT_ALIGNMENT);
  statusMessageMenu=new StatusMessageMenu(protocolProvider,true);
  statusMessageMenu.addPropertyChangeListener(this);
  updateTitleArea();
  this.add(titleArea);
  this.addSeparator();
  while (statusIterator.hasNext()) {
    PresenceStatus status=statusIterator.next();
    byte[] statusIcon=status.getStatusIcon();
    addItem(status.getStatusName(),(statusIcon == null) ? null : new ImageIcon(statusIcon),this);
  }
  this.addSeparator();
  this.add((JMenu)statusMessageMenu.getMenu());
  this.setSelectedStatus(getOfflineStatus());
  updateStatus(getOfflineStatus());
}