mirror of https://github.com/apache/cloudstack.git
fix bug when one of template was deleted, then delpoyvm, got NPE
This commit is contained in:
parent
771ad2ae9a
commit
c2a1f748df
|
|
@ -211,9 +211,7 @@ public abstract class AbstractStoragePoolAllocator extends AdapterBase implement
|
|||
}
|
||||
|
||||
for (VMTemplateStoragePoolVO templatePoolVO : templatePoolVOs) {
|
||||
VMTemplateVO templateInPool = _templateDao.findById(templatePoolVO.getTemplateId());
|
||||
|
||||
if ((template != null) && !tmpinstalled && (templateInPool.getId() == template.getId())) {
|
||||
if ((template != null) && !tmpinstalled && (templatePoolVO.getTemplateId() == template.getId())) {
|
||||
tmpinstalled = true;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue