Program: 103793
Project: 103793
Buggy source:
/** 
 * Invites the given <tt>chatContacts</tt> to this chat.
 * @param inviteChatTransport the chat transport to use to send the invite
 * @param chatContacts the contacts to invite
 * @param reason the reason of the invite
 */
public void inviteContacts(ChatTransport inviteChatTransport,Collection<String> chatContacts,String reason){
  ChatSession conferenceChatSession=null;
  if (chatSession instanceof MetaContactChatSession) {
    chatContacts.add(inviteChatTransport.getName());
    ConferenceChatManager conferenceChatManager=GuiActivator.getUIService().getConferenceChatManager();
    if (inviteChatTransport.getProtocolProvider().getOperationSet(OperationSetMultiUserChat.class) != null) {
      ChatRoomWrapper chatRoomWrapper=conferenceChatManager.createChatRoom(inviteChatTransport.getProtocolProvider(),chatContacts);
      conferenceChatSession=new ConferenceChatSession(this,chatRoomWrapper);
    }
 else     if (inviteChatTransport.getProtocolProvider().getOperationSet(OperationSetAdHocMultiUserChat.class) != null) {
      AdHocChatRoomWrapper chatRoomWrapper=conferenceChatManager.createAdHocChatRoom(inviteChatTransport.getProtocolProvider(),chatContacts,reason);
      conferenceChatSession=new AdHocConferenceChatSession(this,chatRoomWrapper);
    }
    if (conferenceChatSession != null)     this.setChatSession(conferenceChatSession);
  }
 else {
    conferenceChatSession=chatSession;
    for (    String contactAddress : chatContacts) {
      conferenceChatSession.getCurrentChatTransport().inviteChatContact(contactAddress,reason);
    }
  }
}

Fixed version (ground truth):
/** 
 * Invites the given <tt>chatContacts</tt> to this chat.
 * @param inviteChatTransport the chat transport to use to send the invite
 * @param chatContacts the contacts to invite
 * @param reason the reason of the invitation
 */
public void inviteContacts(ChatTransport inviteChatTransport,Collection<String> chatContacts,String reason){
  ChatSession conferenceChatSession=null;
  if (chatSession instanceof MetaContactChatSession) {
    chatContacts.add(inviteChatTransport.getName());
    ConferenceChatManager conferenceChatManager=GuiActivator.getUIService().getConferenceChatManager();
    if (inviteChatTransport.getProtocolProvider().getOperationSet(OperationSetMultiUserChat.class) != null) {
      ChatRoomWrapper chatRoomWrapper=conferenceChatManager.createChatRoom(inviteChatTransport.getProtocolProvider(),chatContacts,reason);
      conferenceChatSession=new ConferenceChatSession(this,chatRoomWrapper);
    }
 else     if (inviteChatTransport.getProtocolProvider().getOperationSet(OperationSetAdHocMultiUserChat.class) != null) {
      AdHocChatRoomWrapper chatRoomWrapper=conferenceChatManager.createAdHocChatRoom(inviteChatTransport.getProtocolProvider(),chatContacts,reason);
      conferenceChatSession=new AdHocConferenceChatSession(this,chatRoomWrapper);
    }
    if (conferenceChatSession != null)     this.setChatSession(conferenceChatSession);
  }
 else {
    conferenceChatSession=chatSession;
    for (    String contactAddress : chatContacts) {
      conferenceChatSession.getCurrentChatTransport().inviteChatContact(contactAddress,reason);
    }
  }
}