Program: 16691
Project: 16691
Buggy source:
/** 
 * Create the menu for the "Text Only" representation of MultipleAlignments
 * @param frame
 * @param actionListener
 * @param multAln 
 * @return a JMenuBar
 */
public static JMenuBar getAlignmentTextMenu(JFrame frame,ActionListener actionListener,MultipleAlignment multAln){
  JMenuBar menu=new JMenuBar();
  JMenu file=new JMenu("String_Node_Str");
  file.getAccessibleContext().setAccessibleDescription("String_Node_Str");
  menu.add(file);
  ImageIcon saveicon=createImageIcon("String_Node_Str");
  JMenuItem saveF=null;
  if (saveicon != null)   saveF=new JMenuItem("String_Node_Str",saveicon);
 else   saveF=new JMenuItem("String_Node_Str");
  saveF.setMnemonic(KeyEvent.VK_S);
  MySaveFileListener listener=new MySaveFileListener(null);
  listener.setFatCatOutput(true);
  saveF.addActionListener(listener);
  file.add(saveF);
  file.addSeparator();
  JMenuItem print=getPrintMenuItem();
  print.addActionListener(actionListener);
  file.add(print);
  file.addSeparator();
  JMenuItem closeI=MenuCreator.getCloseMenuItem(frame);
  file.add(closeI);
  JMenuItem exitI=MenuCreator.getExitMenuItem();
  file.add(exitI);
  JMenu edit=new JMenu("String_Node_Str");
  edit.setMnemonic(KeyEvent.VK_E);
  menu.add(edit);
  JMenuItem eqrI=MenuCreator.getIcon(actionListener,SELECT_EQR);
  edit.add(eqrI);
  JMenuItem eqrcI=MenuCreator.getIcon(actionListener,EQR_COLOR);
  edit.add(eqrcI);
  JMenuItem simI=MenuCreator.getIcon(actionListener,SIMILARITY_COLOR);
  edit.add(simI);
  JMenuItem fatcatI=MenuCreator.getIcon(actionListener,FATCAT_BLOCK);
  edit.add(fatcatI);
  JMenu view=new JMenu("String_Node_Str");
  view.getAccessibleContext().setAccessibleDescription("String_Node_Str");
  view.setMnemonic(KeyEvent.VK_V);
  menu.add(view);
  JMenuItem fastaI=MenuCreator.getIcon(actionListener,FASTA_FORMAT);
  view.add(fastaI);
  JMenuItem pairsI=MenuCreator.getIcon(actionListener,PAIRS_ONLY);
  view.add(pairsI);
  JMenuItem textF=MenuCreator.getIcon(actionListener,FATCAT_TEXT);
  view.add(textF);
  JMenu about=new JMenu("String_Node_Str");
  about.setMnemonic(KeyEvent.VK_A);
  JMenuItem helpM=MenuCreator.getHelpMenuItem();
  about.add(helpM);
  JMenuItem aboutM=MenuCreator.getAboutMenuItem();
  about.add(aboutM);
  menu.add(Box.createGlue());
  menu.add(about);
  return menu;
}

Fixed version (ground truth):
/** 
 * Create the menu for the Text representations of Structural Alignments.
 * @param frame
 * @param actionListener
 * @param afpChain
 * @return a JMenuBar
 */
public static JMenuBar getAlignmentTextMenu(JFrame frame,ActionListener actionListener,AFPChain afpChain){
  JMenuBar menu=new JMenuBar();
  JMenu file=new JMenu("String_Node_Str");
  file.getAccessibleContext().setAccessibleDescription("String_Node_Str");
  menu.add(file);
  ImageIcon saveicon=createImageIcon("String_Node_Str");
  JMenuItem saveF=null;
  if (saveicon != null)   saveF=new JMenuItem("String_Node_Str",saveicon);
 else   saveF=new JMenuItem("String_Node_Str");
  saveF.setMnemonic(KeyEvent.VK_S);
  MySaveFileListener listener=new MySaveFileListener(afpChain);
  listener.setFatCatOutput(true);
  saveF.addActionListener(listener);
  file.add(saveF);
  file.addSeparator();
  JMenuItem print=getPrintMenuItem();
  print.addActionListener(actionListener);
  file.add(print);
  file.addSeparator();
  JMenuItem closeI=MenuCreator.getCloseMenuItem(frame);
  file.add(closeI);
  JMenuItem exitI=MenuCreator.getExitMenuItem();
  file.add(exitI);
  JMenu view=new JMenu("String_Node_Str");
  view.getAccessibleContext().setAccessibleDescription("String_Node_Str");
  view.setMnemonic(KeyEvent.VK_V);
  menu.add(view);
  JMenuItem textI=MenuCreator.getIcon(actionListener,TEXT_ONLY);
  view.add(textI);
  JMenuItem fastaI=MenuCreator.getIcon(actionListener,FASTA_FORMAT);
  view.add(fastaI);
  JMenuItem pairsI=MenuCreator.getIcon(actionListener,PAIRS_ONLY);
  view.add(pairsI);
  JMenuItem textF=MenuCreator.getIcon(actionListener,FATCAT_TEXT);
  view.add(textF);
  JMenu about=new JMenu("String_Node_Str");
  about.setMnemonic(KeyEvent.VK_A);
  JMenuItem helpM=MenuCreator.getHelpMenuItem();
  about.add(helpM);
  JMenuItem aboutM=MenuCreator.getAboutMenuItem();
  about.add(aboutM);
  menu.add(Box.createGlue());
  menu.add(about);
  return menu;
}