Federico Simoncelli has uploaded a new change for review.
Change subject: fileVolume: remove unneeded size conversion in _create ......................................................................
fileVolume: remove unneeded size conversion in _create
It quite some time that blockVolume._create is already treating the size argument as an integer (e.g. in the SECTORS_TO_MB computation). The two places where size is set are: createVolume (hsm.py) where validateN does the integer conversion and volume.getSize where there's and explicit call to int.
Change-Id: I3d27f9bf3d5cbab593103ae0510bdb1c7b5dd240 Signed-off-by: Federico Simoncelli fsimonce@redhat.com --- M vdsm/storage/fileVolume.py 1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/20/27620/1
diff --git a/vdsm/storage/fileVolume.py b/vdsm/storage/fileVolume.py index f2a93d6..2d6d43d 100644 --- a/vdsm/storage/fileVolume.py +++ b/vdsm/storage/fileVolume.py @@ -118,7 +118,7 @@ properly handled and logged in volume.create() """
- sizeBytes = int(size) * BLOCK_SIZE + sizeBytes = size * BLOCK_SIZE
try: oop.getProcessPool(dom.sdUUID).truncateFile(volPath, sizeBytes,
Federico Simoncelli has posted comments on this change.
Change subject: fileVolume: remove unneeded size conversion in _create ......................................................................
Patch Set 1: Verified+1
Verified yesterday as part of http://gerrit.ovirt.org/27544 (tested cases are listed there).
Dan Kenigsberg has posted comments on this change.
Change subject: fileVolume: remove unneeded size conversion in _create ......................................................................
Patch Set 1: Code-Review+2
Dan Kenigsberg has submitted this change and it was merged.
Change subject: fileVolume: remove unneeded size conversion in _create ......................................................................
fileVolume: remove unneeded size conversion in _create
It quite some time that blockVolume._create is already treating the size argument as an integer (e.g. in the SECTORS_TO_MB computation). The two places where size is set are: createVolume (hsm.py) where validateN does the integer conversion and volume.getSize where there's and explicit call to int.
Change-Id: I3d27f9bf3d5cbab593103ae0510bdb1c7b5dd240 Signed-off-by: Federico Simoncelli fsimonce@redhat.com Reviewed-on: http://gerrit.ovirt.org/27620 Reviewed-by: Dan Kenigsberg danken@redhat.com --- M vdsm/storage/fileVolume.py 1 file changed, 1 insertion(+), 1 deletion(-)
Approvals: Federico Simoncelli: Verified Dan Kenigsberg: Looks good to me, approved
oVirt Jenkins CI Server has posted comments on this change.
Change subject: fileVolume: remove unneeded size conversion in _create ......................................................................
Patch Set 2:
Build Successful
http://jenkins.ovirt.org/job/vdsm_master_create-rpms_merged/1290/ : SUCCESS
oVirt Jenkins CI Server has posted comments on this change.
Change subject: fileVolume: remove unneeded size conversion in _create ......................................................................
Patch Set 1:
Build Successful
http://jenkins.ovirt.org/job/vdsm_master_pep8_gerrit/8779/ : SUCCESS
http://jenkins.ovirt.org/job/vdsm_master_unit_tests_gerrit/8915/ : SUCCESS
http://jenkins.ovirt.org/job/vdsm_master_unit_tests_gerrit_el/7989/ : SUCCESS
vdsm-patches@lists.fedorahosted.org