mirror of
https://github.com/apache/cloudstack.git
synced 2025-10-26 08:42:29 +01:00
api: Prevent null pointer on listPublicIpAddress cmd (#4255)
* Prevent null pointer on listPublicIpAddress cmd Insert an inner join between data_center table and user_ip_address where data_center.removed field is null * Remove extra join and add a filter for VLAN removed
This commit is contained in:
parent
6704ef2794
commit
3adee270c7
@ -1983,6 +1983,7 @@ public class ManagementServerImpl extends ManagerBase implements ManagementServe
|
||||
|
||||
final SearchBuilder<VlanVO> vlanSearch = _vlanDao.createSearchBuilder();
|
||||
vlanSearch.and("vlanType", vlanSearch.entity().getVlanType(), SearchCriteria.Op.EQ);
|
||||
vlanSearch.and("removed", vlanSearch.entity().getRemoved(), SearchCriteria.Op.NULL);
|
||||
sb.join("vlanSearch", vlanSearch, sb.entity().getVlanId(), vlanSearch.entity().getId(), JoinBuilder.JoinType.INNER);
|
||||
|
||||
if (isAllocated != null && isAllocated == true) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user