Author: toad
Date: 2008-11-27 18:53:23 +0000 (Thu, 27 Nov 2008)
New Revision: 23916

Modified:
   trunk/freenet/src/freenet/clients/http/WelcomeToadlet.java
Log:
Fix NPE when plugins haven't loaded yet.


Modified: trunk/freenet/src/freenet/clients/http/WelcomeToadlet.java
===================================================================
--- trunk/freenet/src/freenet/clients/http/WelcomeToadlet.java  2008-11-27 
18:39:02 UTC (rev 23915)
+++ trunk/freenet/src/freenet/clients/http/WelcomeToadlet.java  2008-11-27 
18:53:23 UTC (rev 23916)
@@ -564,7 +564,8 @@
         HTMLNode bookmarkBoxContent = bookmarkBox.addChild("div", "class", 
"infobox-content");
         
         // Search box
-        
if(core.node.pluginManager.isPluginLoaded("plugins.XMLLibrarian.XMLLibrarian")) 
{
+        if(core.node.pluginManager != null && 
+                       
core.node.pluginManager.isPluginLoaded("plugins.XMLLibrarian.XMLLibrarian")) {
                HTMLNode form = bookmarkBoxContent.addChild("form", new 
String[] { "method", "action" }, new String[] { "GET", 
"/plugins/plugins.XMLLibrarian.XMLLibrarian" });
                form.addChild("input", new String[] { "type", "name", "value" 
}, new String[] { "hidden", "choice", "index" });
                form.addChild("input", new String[] { "type", "size", "name" }, 
new String[] { "text", "80", "search" });

_______________________________________________
cvs mailing list
[email protected]
http://emu.freenetproject.org/cgi-bin/mailman/listinfo/cvs

Reply via email to