fix a NPE when destroying a detached volume

This commit is contained in:
edison 2010-12-17 10:43:00 -08:00
parent 18762b397d
commit 5b39bd6872
1 changed files with 4 additions and 4 deletions

View File

@ -35,7 +35,7 @@ public class VolumeTO {
private Storage.StorageResourceType resourceType;
private StoragePoolType storagePoolType;
private String storagePoolUuid;
private int deviceId;
private long deviceId;
private String chainInfo;
public VolumeTO(long id, Volume.VolumeType type, Storage.StorageResourceType resourceType, StoragePoolType poolType,
@ -63,14 +63,14 @@ public class VolumeTO {
this.storagePoolUuid = pool.getUuid();
this.mountPoint = volume.getFolder();
this.chainInfo = volume.getChainInfo();
this.deviceId = volume.getDeviceId().intValue();
this.deviceId = volume.getDeviceId();
}
public int getDeviceId() {
public long getDeviceId() {
return deviceId;
}
public void setDeviceId(int id) {
public void setDeviceId(long id) {
this.deviceId = id;
}