From f94cc60becf0c18c0966d20d222552b9e7585f9e Mon Sep 17 00:00:00 2001
From: Ludovic Poitou <ludovic.poitou@forgerock.com>
Date: Tue, 03 Jan 2012 16:51:37 +0000
Subject: [PATCH] Fix minor issues and optimizations suggested by FindBugs and NetBeans.
---
opends/src/server/org/opends/server/tools/CreateRCScript.java | 22 ++++++----------------
1 files changed, 6 insertions(+), 16 deletions(-)
diff --git a/opends/src/server/org/opends/server/tools/CreateRCScript.java b/opends/src/server/org/opends/server/tools/CreateRCScript.java
index a325462..9e51919 100644
--- a/opends/src/server/org/opends/server/tools/CreateRCScript.java
+++ b/opends/src/server/org/opends/server/tools/CreateRCScript.java
@@ -23,7 +23,7 @@
*
*
* Copyright 2008 Sun Microsystems, Inc.
- * Portions Copyright 2010-2011 ForgeRock AS
+ * Portions Copyright 2010-2012 ForgeRock AS
*/
package org.opends.server.tools;
@@ -97,16 +97,6 @@
public static int main(String[] args, OutputStream outStream,
OutputStream errStream)
{
- PrintStream out;
- if (outStream == null)
- {
- out = NullOutputStream.printStream();
- }
- else
- {
- out = new PrintStream(outStream);
- }
-
PrintStream err;
if (errStream == null)
{
@@ -140,11 +130,11 @@
ArgumentParser argParser =
new ArgumentParser(CreateRCScript.class.getName(), description, false);
- BooleanArgument showUsage = null;
- StringArgument javaArgs = null;
- StringArgument javaHome = null;
- StringArgument outputFile = null;
- StringArgument userName = null;
+ BooleanArgument showUsage;
+ StringArgument javaArgs;
+ StringArgument javaHome;
+ StringArgument outputFile;
+ StringArgument userName;
try
{
--
Gitblit v1.10.0