From 55b437508acb80b4931a5d7f37b987adf367fa46 Mon Sep 17 00:00:00 2001
From: Ludovic Poitou <ludovic.poitou@forgerock.com>
Date: Thu, 05 Jan 2012 17:37:33 +0000
Subject: [PATCH] Spring cleaning ! Fix minor issues and optimizations suggested by FindBugs and NetBeans.
---
opends/src/server/org/opends/server/plugins/profiler/ProfileViewer.java | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/opends/src/server/org/opends/server/plugins/profiler/ProfileViewer.java b/opends/src/server/org/opends/server/plugins/profiler/ProfileViewer.java
index d100c4d..ed680c6 100644
--- a/opends/src/server/org/opends/server/plugins/profiler/ProfileViewer.java
+++ b/opends/src/server/org/opends/server/plugins/profiler/ProfileViewer.java
@@ -23,6 +23,7 @@
*
*
* Copyright 2006-2008 Sun Microsystems, Inc.
+ * Portions Copyright 2012 ForgeRock AS
*/
package org.opends.server.plugins.profiler;
import org.opends.messages.Message;
@@ -100,7 +101,7 @@
public static void main(String[] args)
{
// Define the command-line arguments that may be used with this program.
- BooleanArgument displayUsage = null;
+ BooleanArgument displayUsage;
BooleanArgument useGUI = null;
StringArgument fileNames = null;
@@ -418,8 +419,8 @@
"captured over " + totalDuration + " milliseconds";
DefaultMutableTreeNode rootNode = new DefaultMutableTreeNode(label, true);
- ProfileStackFrame[] rootFrames = getRootFrames();
- if (rootFrames.length == 0)
+ ProfileStackFrame[] theRootFrames = getRootFrames();
+ if (theRootFrames.length == 0)
{
System.err.println("ERROR: No data available for viewing.");
return;
@@ -475,7 +476,6 @@
return;
}
- String largestCountString = String.valueOf(subFrames[0].getTotalCount());
for (ProfileStackFrame subFrame : subFrames)
{
@@ -524,6 +524,7 @@
* @param tse The tree selection event with information about the selection
* or deselection that occurred.
*/
+ @Override
public void valueChanged(TreeSelectionEvent tse)
{
try
--
Gitblit v1.10.0