Buggy code:
public class PluginInstaller { public static interface PluginInstallerListener extends EventListener { public void pluginInstalled ( boolean success ) { } public void pluginRemoved ( boolean success ) { } } private static class PluginInstallInfo { final PluginRepositoryLoader loader ; final PluginDescriptor plugin ; final boolean showConfirm ; public PluginInstallInfo ( PluginRepositoryLoader loader , PluginDescriptor plugin , boolean showConfirm ) { } } private static final String ERROR_DOWNLOAD = "Error<seq2seq4repair_space>while<seq2seq4repair_space>downloading<seq2seq4repair_space>" ; private static final String ERROR_SAVE = "Error<seq2seq4repair_space>while<seq2seq4repair_space>saving" ; private static final String INSTALL_INTERRUPT = "Plugin<seq2seq4repair_space>installation<seq2seq4repair_space>canceled<seq2seq4repair_space>by<seq2seq4repair_space>user." ; private static final ArrayList < PluginInstaller . PluginInstallInfo > installFIFO = new ArrayList < PluginInstaller . PluginInstallInfo > ( ) ; private static final ArrayList < PluginInstaller . PluginInstallInfo > removeFIFO = new ArrayList < PluginInstaller . PluginInstallInfo > ( ) ; private static final SingleProcessor processor = new SingleProcessor ( true ) ; private static final Runnable runner = new Runnable ( ) { @ Override public void run ( ) { } } ; private static ArrayList < PluginDescriptor > installingPlugins = new ArrayList < PluginDescriptor > ( ) ; private static PluginDescriptor desinstallingPlugin = null ; private static boolean installing = false ; private static boolean deinstalling = false ; private static final EventListenerList listeners = new EventListenerList ( ) ; private static boolean canInstallOrDesinstall ( ) { } public static void install ( PluginRepositoryLoader loader , PluginDescriptor plugin , boolean showConfirm ) { } public static boolean isProcessing ( ) { } public static ArrayList < PluginInstaller . PluginInstallInfo > getInstallFIFO ( ) { } public static boolean isInstalling ( ) { } public static boolean isWaitingForInstall ( PluginDescriptor plugin ) { } public static boolean isInstallingPlugin ( PluginDescriptor plugin ) { } public static void desinstall ( PluginDescriptor plugin , boolean showConfirm ) { } public static ArrayList < PluginInstaller . PluginInstallInfo > getRemoveFIFO ( ) { } public static boolean isDesinstalling ( ) { } public static boolean isWaitingForDesinstall ( PluginDescriptor plugin ) { } public static boolean isDesinstallingPlugin ( PluginDescriptor plugin ) { } static void processTasks ( ) { } private static String backup ( PluginDescriptor plugin ) { } private static String downloadAndSavePlugin ( PluginDescriptor plugin , CancelableProgressFrame taskFrame ) { } private static String downloadAndSave ( String downloadPath , String savePath , boolean displayError , ProgressFrame taskFrame ) { } private static boolean deletePlugin ( PluginDescriptor plugin ) { if ( ! ( FileUtil . delete ( plugin . getJarFilename ( ) , false ) ) ) { System . err . println ( ( "deletePlugin()<seq2seq4repair_space>:<seq2seq4repair_space>Can't<seq2seq4repair_space>delete<seq2seq4repair_space>" + ( plugin . getJarFilename ( ) ) ) ) ; return false ; } <START_BUG> if ( FileUtil . exist ( plugin . getXMLFilename ( ) ) ) <END_BUG> if ( ! ( FileUtil . delete ( plugin . getXMLFilename ( ) , false ) ) ) System . err . println ( ( "deletePlugin()<seq2seq4repair_space>:<seq2seq4repair_space>Can't<seq2seq4repair_space>delete<seq2seq4repair_space>" + ( plugin . getXMLFilename ( ) ) ) ) ; FileUtil . delete ( plugin . getImageFilename ( ) , false ) ; FileUtil . delete ( plugin . getIconFilename ( ) , false ) ; return true ; } public static void getLocalDependenciesOf ( ArrayList < PluginDescriptor > result , PluginDescriptor plugin ) { } public static ArrayList < PluginDescriptor > getLocalDependenciesFrom ( PluginDescriptor plugin ) { } private static void getLocalDependenciesOf ( ArrayList < PluginDescriptor > result , ArrayList < PluginDescriptor > sources , PluginDescriptor plugin ) { } public static ArrayList < PluginDescriptor > getDependenciesOrderedList ( ArrayList < PluginDescriptor > plugins ) { } private static boolean checkDependencies ( PluginRepositoryLoader reposLoader , PluginDescriptor plugin , ArrayList < PluginDescriptor > pluginsToInstall , CancelableProgressFrame taskFrame ) { } private static boolean internal_install ( PluginInstaller . PluginInstallInfo installInfo ) { } private static boolean internal_desinstall ( PluginInstaller . PluginInstallInfo installInfo ) { } public static void addListener ( PluginInstaller . PluginInstallerListener listener ) { } public static void removeListener ( PluginInstaller . PluginInstallerListener listener ) { } private static void fireInstalledEvent ( boolean success ) { } private static void fireRemovedEvent ( boolean success ) { } }

Fix:
if ( FileUtil . exists ( plugin . getXMLFilename ( ) ) )