This is an automated email from the ASF dual-hosted git repository.
dahn pushed a commit to branch 4.11
in repository https://gitbox.apache.org/repos/asf/cloudstack.git
The following commit(s) were added to refs/heads/4.11 by this push:
new b69c378 [Vmware] Fix for OVF parsing error (#2567)
b69c378 is described below
commit b69c37862c30e231e4ec3622a73ea619c9ad9fbc
Author: Nicolas Vazquez <[email protected]>
AuthorDate: Fri Apr 13 06:19:30 2018 -0300
[Vmware] Fix for OVF parsing error (#2567)
---
api/src/com/cloud/agent/api/storage/OVFHelper.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/api/src/com/cloud/agent/api/storage/OVFHelper.java
b/api/src/com/cloud/agent/api/storage/OVFHelper.java
index 167d5d4..85d4030 100644
--- a/api/src/com/cloud/agent/api/storage/OVFHelper.java
+++ b/api/src/com/cloud/agent/api/storage/OVFHelper.java
@@ -113,7 +113,7 @@ public class OVFHelper {
String allocationUnits =
disk.getAttribute("ovf:capacityAllocationUnits");
od._diskId = disk.getAttribute("ovf:diskId");
od._fileRef = disk.getAttribute("ovf:fileRef");
- od._populatedSize =
Long.parseLong(disk.getAttribute("ovf:populatedSize") == null ? "0" :
disk.getAttribute("ovf:populatedSize"));
+ od._populatedSize =
NumberUtils.toLong(disk.getAttribute("ovf:populatedSize"));
if ((od._capacity != 0) && (allocationUnits != null)) {
--
To stop receiving notification emails like this one, please contact
[email protected].