Buggy code:
class HelpTOCPanel extends JPanel { public HelpTOCPanel ( HelpViewer helpViewer ) { } public void selectNode ( String shortURL ) { } private HelpViewer helpViewer ; private DefaultTreeModel tocModel ; private DefaultMutableTreeNode tocRoot ; private JTree toc ; private Hashtable nodes ; private DefaultMutableTreeNode createNode ( String href , String title ) { } private void createTOC ( ) { tocRoot = new DefaultMutableTreeNode ( ) ; tocRoot . add ( createNode ( "welcome.html" , jEdit . getProperty ( "helpviewer.toc.welcome" ) ) ) ; tocRoot . add ( createNode ( "README.txt" , jEdit . getProperty ( "helpviewer.toc.readme" ) ) ) ; tocRoot . add ( createNode ( "NEWS.txt" , jEdit . getProperty ( "helpviewer.toc.news" ) ) ) ; tocRoot . add ( createNode ( "CHANGES.txt" , jEdit . getProperty ( "helpviewer.toc.changes" ) ) ) ; tocRoot . add ( createNode ( "TODO.txt" , jEdit . getProperty ( "helpviewer.toc.todo" ) ) ) ; tocRoot . add ( createNode ( "COPYING.txt" , jEdit . getProperty ( "helpviewer.toc.copying" ) ) ) ; tocRoot . add ( createNode ( "COPYING.DOC.txt" , jEdit . getProperty ( "helpviewer.toc.copying-doc" ) ) ) ; loadTOC ( tocRoot , "users-guide//toc.xml" ) ; loadTOC ( tocRoot , "FAQ//toc.xml" ) ; loadTOC ( tocRoot , "api//toc.xml" ) ; DefaultMutableTreeNode pluginTree = new DefaultMutableTreeNode ( jEdit . getProperty ( "helpviewer.toc.plugins" ) , true ) ; EditPlugin [ ] plugins = jEdit . getPlugins ( ) ; for ( int i = 0 ; i < ( plugins . length ) ; i ++ ) { EditPlugin plugin = plugins [ i ] ; <START_BUG> EditPlugin . JAR jar = plugin . getJAR ( ) ; <END_BUG> if ( jar == null ) continue ; String name = plugin . getClassName ( ) ; String docs = jEdit . getProperty ( ( ( "plugin." + name ) + ".docs" ) ) ; String label = jEdit . getProperty ( ( ( "plugin." + name ) + ".name" ) ) ; if ( docs != null ) { if ( ( label != null ) && ( docs != null ) ) { URL url = jar . getClassLoader ( ) . getResource ( docs ) ; if ( url != null ) { pluginTree . add ( createNode ( url . toString ( ) , label ) ) ; } } } } if ( ( pluginTree . getChildCount ( ) ) != 0 ) tocRoot . add ( pluginTree ) ; else { pluginTree = null ; } tocModel = new DefaultTreeModel ( tocRoot ) ; } private void loadTOC ( DefaultMutableTreeNode root , String path ) { } static class HelpNode { String href ; String title ; HelpNode ( String href , String title ) { } public String toString ( ) { } } class TOCHandler extends HandlerBase { String dir ; TOCHandler ( DefaultMutableTreeNode root , String dir ) { } public void attribute ( String aname , String value , boolean isSpecified ) { } public void charData ( char [ ] c , int off , int len ) { } public void startElement ( String name ) { } public void endElement ( String name ) { } private String tag ; private String title ; private String href ; private DefaultMutableTreeNode node ; private Stack nodes ; } class TOCTree extends JTree { TOCTree ( TreeModel model ) { } public final String getToolTipText ( MouseEvent evt ) { } protected void processMouseEvent ( MouseEvent evt ) { } private int toolTipInitialDelay = - 1 ; private int toolTipReshowDelay = - 1 ; private boolean cellRectIsVisible ( Rectangle cellRect ) { } } class TOCCellRenderer extends DefaultTreeCellRenderer { EmptyBorder border = new EmptyBorder ( 1 , 0 , 1 , 1 ) ; public Component getTreeCellRendererComponent ( JTree tree , Object value , boolean sel , boolean expanded , boolean leaf , int row , boolean focus ) { } } }

Fix:
PluginJAR jar = plugin . getJAR ( ) ;