Skip to content

Commit

Permalink
Update plugins/hypervisors/xenserver/src/main/java/com/cloud/hypervis…
Browse files Browse the repository at this point in the history
…or/xenserver/resource/CitrixResourceBase.java
  • Loading branch information
weizhouapache authored Aug 28, 2023
1 parent 2ee9274 commit d72745f
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1338,7 +1338,7 @@ public VM createVmFromTemplate(final Connection conn, final VirtualMachineTO vmS
vmr.VCPUsMax = (long)vmSpec.getCpus();
} else {
if (vmSpec.getVcpuMaxLimit() != null) {
vmr.VCPUsMax = Math.min(vmSpec.getVcpuMaxLimit(), _host.getCpus());
vmr.VCPUsMax = Math.min(vmSpec.getVcpuMaxLimit(), (long) _host.getCpus());
}
}
} else {
Expand Down

0 comments on commit d72745f

Please sign in to comment.