[Yum-devel] [PATCH 1/3] Use TMPDIR, if set, for save_ts. BZ 723280.

seth vidal skvidal at fedoraproject.org
Tue Jul 19 20:33:17 UTC 2011


On Tue, 2011-07-19 at 15:53 -0400, James Antill wrote:
> ---
>  yum/__init__.py |    3 ++-
>  1 files changed, 2 insertions(+), 1 deletions(-)
> 
> diff --git a/yum/__init__.py b/yum/__init__.py
> index 12c2bdd..3f7f619 100644
> --- a/yum/__init__.py
> +++ b/yum/__init__.py
> @@ -5242,7 +5242,8 @@ class YumBase(depsolve.Depsolve):
>          
>          if not filename:
>              prefix = 'yum_save_tx-%s' % time.strftime('%Y-%m-%d-%H-%M')
> -            fd,filename = tempfile.mkstemp(suffix='.yumtx', prefix=prefix)
> +            fd,filename = tempfile.mkstemp(suffix='.yumtx', prefix=prefix,
> +                                           dir=os.getenv('TMPDIR'))
>              f = os.fdopen(fd, 'w')
>          else:
>              f = open(filename, 'w')

ACK
-sv




More information about the Yum-devel mailing list