diff options
| author | Vishvananda Ishaya <vishvananda@gmail.com> | 2010-07-23 17:20:21 -0700 |
|---|---|---|
| committer | Vishvananda Ishaya <vishvananda@gmail.com> | 2010-07-23 17:20:21 -0700 |
| commit | a0c29a822aaed756728f2619e176d8c54bb1d4e9 (patch) | |
| tree | d8ecdd5ded0b9027b3bd9e1d76fd937e6ac25285 | |
| parent | 4efa1cd41b5366f5bb528c0db21908a66f785557 (diff) | |
fixed bug where partition code was sometimes failing due to initial dd not being yielded properly
| -rw-r--r-- | nova/compute/disk.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/nova/compute/disk.py b/nova/compute/disk.py index 08a22556e..7e31498e5 100644 --- a/nova/compute/disk.py +++ b/nova/compute/disk.py @@ -64,8 +64,8 @@ def partition(infile, outfile, local_bytes=0, local_type='ext2', execute=None): last_sector = local_last # e # create an empty file - execute('dd if=/dev/zero of=%s count=1 seek=%d bs=%d' - % (outfile, last_sector, sector_size)) + yield execute('dd if=/dev/zero of=%s count=1 seek=%d bs=%d' + % (outfile, last_sector, sector_size)) # make mbr partition yield execute('parted --script %s mklabel msdos' % outfile) |
