From 05c9d54c4fdf32bef9fd6ae3cf20f9fca77cd137 Mon Sep 17 00:00:00 2001 From: Laszlo Hornyak Date: Tue, 25 Mar 2014 20:57:16 +0100 Subject: [PATCH] removed Integer and Long instantiations Signed-off-by: Laszlo Hornyak --- .../cloud/network/security/SecurityGroupWorkTracker.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/server/src/com/cloud/network/security/SecurityGroupWorkTracker.java b/server/src/com/cloud/network/security/SecurityGroupWorkTracker.java index 6bc49df3b5f..63b1cbb6be9 100644 --- a/server/src/com/cloud/network/security/SecurityGroupWorkTracker.java +++ b/server/src/com/cloud/network/security/SecurityGroupWorkTracker.java @@ -48,8 +48,8 @@ public class SecurityGroupWorkTracker { synchronized (this) { Integer outstanding = _unackedMessages.get(agentId); if (outstanding == null) { - outstanding = new Integer(0); - _unackedMessages.put(new Long(agentId), outstanding); + outstanding = 0; + _unackedMessages.put(agentId, outstanding); } currLength = outstanding.intValue(); if (currLength + 1 > _bufferLength) { @@ -58,7 +58,7 @@ public class SecurityGroupWorkTracker { s_logger.debug("SecurityGroupManager: dropping a message because there are more than " + currLength + " outstanding messages, total dropped=" + discarded); return false; } - _unackedMessages.put(new Long(agentId), ++currLength); + _unackedMessages.put(agentId, ++currLength); } return true; }