@@ -1956,7 +1956,6 @@ protected String networkUsage(Connection conn, final String privateIpAddress, fi
19561956
19571957 protected ExecutionResult prepareNetworkElementCommand (IpAssocCommand cmd ) {
19581958 Connection conn = getConnection ();
1959- int i = 0 ;
19601959 String routerName = cmd .getAccessDetail (NetworkElementCommand .ROUTER_NAME );
19611960 String routerIp = cmd .getAccessDetail (NetworkElementCommand .ROUTER_IP );
19621961
@@ -2029,8 +2028,6 @@ protected ExecutionResult prepareNetworkElementCommand(IpAssocCommand cmd) {
20292028
20302029 protected ExecutionResult cleanupNetworkElementCommand (IpAssocCommand cmd ) {
20312030 Connection conn = getConnection ();
2032- String [] results = new String [cmd .getIpAddresses ().length ];
2033- int i = 0 ;
20342031 String routerName = cmd .getAccessDetail (NetworkElementCommand .ROUTER_NAME );
20352032 String routerIp = cmd .getAccessDetail (NetworkElementCommand .ROUTER_IP );
20362033 try {
@@ -7307,19 +7304,18 @@ protected ExecutionResult prepareNetworkElementCommand(IpAssocVpcCommand cmd) {
73077304 return new ExecutionResult (true , null );
73087305 }
73097306
7310- protected void setNicDevIdIfCorrectVifIsNotNull (Connection conn ,
7311- IpAddressTO ip , VIF correctVif ) throws InternalErrorException ,
7312- BadServerResponse , XenAPIException , XmlRpcException {
7313- if (correctVif == null ) {
7314- if (ip .isAdd ()) {
7315- throw new InternalErrorException ("Failed to find DomR VIF to associate IP with." );
7316- } else {
7317- s_logger .debug ("VIF to deassociate IP with does not exist, return success" );
7318- }
7319- } else {
7320- ip .setNicDevId (Integer .valueOf (correctVif .getDevice (conn )));
7321- }
7322- }
7307+ protected void setNicDevIdIfCorrectVifIsNotNull (Connection conn , IpAddressTO ip , VIF correctVif ) throws InternalErrorException , BadServerResponse , XenAPIException ,
7308+ XmlRpcException {
7309+ if (correctVif == null ) {
7310+ if (ip .isAdd ()) {
7311+ throw new InternalErrorException ("Failed to find DomR VIF to associate IP with." );
7312+ } else {
7313+ s_logger .debug ("VIF to deassociate IP with does not exist, return success" );
7314+ }
7315+ } else {
7316+ ip .setNicDevId (Integer .valueOf (correctVif .getDevice (conn )));
7317+ }
7318+ }
73237319
73247320 protected ExecutionResult prepareNetworkElementCommand (SetSourceNatCommand cmd ) {
73257321 Connection conn = getConnection ();
0 commit comments