mirror of https://github.com/apache/cloudstack.git
fixed NPE, secondary storage VM host may not exist even the secondary storage VM is running
This commit is contained in:
parent
bad0f77659
commit
4c8f5e0591
|
|
@ -391,6 +391,9 @@ public class SecondaryStorageManagerImpl implements SecondaryStorageVmManager, V
|
|||
}
|
||||
String instanceName = ssVm.getInstanceName();
|
||||
HostVO host = _hostDao.findByName(instanceName);
|
||||
if ( host == null ) {
|
||||
continue;
|
||||
}
|
||||
Answer answer = _agentMgr.easySend(host.getId(), thiscpc);
|
||||
if (answer != null && answer.getResult()) {
|
||||
if (s_logger.isDebugEnabled()) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue