mirror of
https://github.com/apache/cloudstack.git
synced 2025-11-03 04:12:31 +01:00
fix bug when one of template was deleted, then delpoyvm, got NPE
This commit is contained in:
parent
c4ac92af3f
commit
ccab6c21c4
@ -212,9 +212,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…
x
Reference in New Issue
Block a user