Allow a command to throw an exception.
[Sone.git] / src / main / java / net / pterodactylus / sone / freenet / fcp / FcpInterface.java
index 3657f8f..de8718f 100644 (file)
@@ -81,8 +81,8 @@ public class FcpInterface {
                        /* TODO - return error? */
                        return;
                }
-               Reply reply = command.execute(parameters, data, AccessType.values()[accessType]);
                try {
+                       Reply reply = command.execute(parameters, data, AccessType.values()[accessType]);
                        SimpleFieldSet replyParameters = reply.getReplyParameters();
                        replyParameters.putOverwrite("Identifier", identifier);
                        if (reply.hasData()) {
@@ -92,6 +92,8 @@ public class FcpInterface {
                        } else {
                                pluginReplySender.send(replyParameters);
                        }
+               } catch (FcpException fe1) {
+                       /* TODO - log, report */
                } catch (PluginNotFoundException pnfe1) {
                        /* TODO - log */
                }