FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Debian > Debian Development

 
 
LinkBack Thread Tools
 
Old 03-15-2009, 05:21 PM
David Lehman
 
Default Explicitly set exists=False when creating newPartitions

On Fri, 2009-03-13 at 18:09 -1000, David Cantrell wrote:
> For autopartition requests as well as free space regions, set
> exists=False when calling newPartition().

I think this was an attempt to work around that bug in
PartitionDeviceFactory that caused it to return None in some cases. If
so, let's get rid of it now that the bug's fixed. The constructor
defaults the argument to None, which should be sufficient in all cases.

Dave

> ---
> storage/partitioning.py | 6 ++++--
> 1 files changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/storage/partitioning.py b/storage/partitioning.py
> index 47800da..7e84489 100644
> --- a/storage/partitioning.py
> +++ b/storage/partitioning.py
> @@ -68,7 +68,8 @@ def _createFreeSpacePartitions(anaconda):
> part = anaconda.id.storage.newPartition(fmt_type=fmt_type ,
> size=1,
> grow=True,
> - disks=[disk])
> + disks=[disk],
> + exists=False)
> if part:
> anaconda.id.storage.createDevice(part)
> devs.append(part)
> @@ -95,7 +96,8 @@ def _schedulePartitions(anaconda, disks):
> grow=grow,
> maxsize=maxsize,
> mountpoint=mountpoint,
> - disks=disks)
> + disks=disks,
> + exists=False)
>
> # schedule the device for creation
> anaconda.id.storage.createDevice(dev)

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list
 

Thread Tools




All times are GMT. The time now is 01:31 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org