Buggy code:
public class PluginManager extends JDialog { public PluginManager ( Frame frame ) { } private JTree tree ; private JLabel name ; private JLabel author ; private JLabel version ; private JButton remove ; private JButton update ; private JButton install ; private JButton close ; private void updateTree ( ) { } class Entry { String clazz ; String name ; String version ; String author ; Vector jars ; boolean broken ; Entry ( String path , String clazz , boolean broken ) { } public String toString ( ) { } } class ActionHandler implements ActionListener { public void actionPerformed ( ActionEvent evt ) { Object source = evt . getSource ( ) ; if ( source == ( close ) ) dispose ( ) ; else if ( source == ( remove ) ) { TreePath [ ] selected = tree . getSelectionModel ( ) . getSelectionPaths ( ) ; StringBuffer buf = new StringBuffer ( ) ; Roster roster = new Roster ( ) ; for ( int i = 0 ; i < ( selected . length ) ; i ++ ) { Object last = ( ( DefaultMutableTreeNode ) ( selected [ i ] . getLastPathComponent ( ) ) ) . getUserObject ( ) ; if ( last instanceof PluginManager . Entry ) { PluginManager . Entry entry = ( ( PluginManager . Entry ) ( last ) ) ; for ( int j = 0 ; j < ( entry . jars . size ( ) ) ; j ++ ) { String jar = ( ( String ) ( entry . jars . elementAt ( j ) ) ) ; if ( ( buf . length ( ) ) != 0 ) buf . append ( '\n' ) ; buf . append ( jar ) ; roster . addOperation ( new Roster . Remove ( jar ) ) ; } } } String [ ] args = new String [ ] { buf . toString ( ) } ; if ( ( GUIUtilities . confirm ( PluginManager . this , "plugin-manager.remove-confirm" , args , JOptionPane . YES_NO_OPTION , JOptionPane . QUESTION_MESSAGE ) ) == ( JOptionPane . YES_OPTION ) ) { new PluginManagerProgress ( PluginManager . this , "remove" , roster ) ; updateTree ( ) ; } } else if ( source == ( update ) ) { PluginList list = new PluginListDownloadProgress ( PluginManager . this ) . getPluginList ( ) ; if ( list == null ) return ; if ( ( jEdit . getSettingsDirectory ( ) ) == null ) { GUIUtilities . error ( PluginManager . this , "no-settings" , null ) ; return ; } Vector plugins = new Vector ( ) ; for ( int i = 0 ; i < ( list . plugins . size ( ) ) ; i ++ ) { PluginList . Plugin plugin = ( ( PluginList . Plugin ) ( list . plugins . elementAt ( i ) ) ) ; PluginList . Branch branch = plugin . getCompatibleBranch ( ) ; if ( ( ( branch != null ) && ( ( plugin . installedVersion ) != null ) ) && ( ( MiscUtilities . compareStrings ( branch . version , plugin . installedVersion , false ) ) > 0 ) ) plugins . addElement ( plugin ) ; } if ( ( plugins . size ( ) ) == 0 ) { GUIUtilities . message ( PluginManager . this , "plugin-manager.up-to-date" , null ) ; return ; } Roster roster = new Roster ( ) ; new InstallPluginsDialog ( PluginManager . this , plugins , InstallPluginsDialog . UPDATE ) . installPlugins ( roster ) ; if ( roster . isEmpty ( ) ) return ; new PluginManagerProgress ( PluginManager . this , "update" , roster ) ; updateTree ( ) ; } else if ( source == ( install ) ) { PluginList list = new PluginListDownloadProgress ( PluginManager . this ) . getPluginList ( ) ; if ( list == null ) return ; if ( ( ( jEdit . getSettingsDirectory ( ) ) == null ) && ( ( jEdit . getJEditHome ( ) ) == null ) ) { GUIUtilities . error ( PluginManager . this , "no-settings" , null ) ; return ; } Vector plugins = new Vector ( ) ; for ( int i = 0 ; i < ( list . plugins . size ( ) ) ; i ++ ) { PluginList . Plugin plugin = ( ( PluginList . Plugin ) ( list . plugins . elementAt ( i ) ) ) ; if ( ( ( plugin . installed ) == null ) && ( plugin . canBeInstalled ( ) ) ) plugins . addElement ( plugin ) ; } Roster roster = new Roster ( ) ; new InstallPluginsDialog ( PluginManager . this , plugins , InstallPluginsDialog . INSTALL ) . installPlugins ( roster ) ; if ( roster . isEmpty ( ) ) return ; <START_BUG> new PluginManagerProgress ( PluginManager . this , "remove" , roster ) ; <END_BUG> updateTree ( ) ; } } } class TreeHandler implements TreeSelectionListener { public void valueChanged ( TreeSelectionEvent evt ) { } } class Renderer extends DefaultTreeCellRenderer { public Component getTreeCellRendererComponent ( JTree tree , Object value , boolean selected , boolean expanded , boolean leaf , int row , boolean hasFocus ) { } } }

Fix:
new PluginManagerProgress ( PluginManager . this , "install" , roster ) ;