[Openais] [PATCH] fix deletion of the tmp root for augeas

Steven Dake sdake at redhat.com
Wed Mar 10 14:47:17 PST 2010


good for merge

On Tue, 2010-03-09 at 07:05 +1100, Angus Salkeld wrote:
> Fix a bug in the cts code (if the tmp directory does not
> exist yet).
> 
> 
> Signed-off-by: Angus Salkeld <asalkeld at redhat.com>
> ---
>  cts/corosync.py |    3 ++-
>  1 files changed, 2 insertions(+), 1 deletions(-)
> 
> diff --git a/cts/corosync.py b/cts/corosync.py
> index 1c3ee7d..09c55af 100644
> --- a/cts/corosync.py
> +++ b/cts/corosync.py
> @@ -60,7 +60,8 @@ class CoroConfig(object):
>              self.corobase = corobase
>          example = self.corobase + "/conf/corosync.conf.example"
>  
> -        shutil.rmtree (self.new_root)
> +        if os.path.isdir(self.new_root):
> +            shutil.rmtree (self.new_root)
>          os.makedirs (self.new_root + "/etc/corosync")
>          shutil.copy (example, self.new_root + "/etc/corosync/corosync.conf")
>  



More information about the Openais mailing list