Re: [newui] [PATCH] Use os.path.normpath when concatenating two absolute paths

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



ack

----- Original Message -----
> os.path.join returns the second argument if it is an absolute path
> ---
>  pyanaconda/keyboard.py  |    2 +-
>  pyanaconda/kickstart.py |    2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/pyanaconda/keyboard.py b/pyanaconda/keyboard.py
> index b95e8d9..d0497d6 100755
> --- a/pyanaconda/keyboard.py
> +++ b/pyanaconda/keyboard.py
> @@ -108,7 +108,7 @@ def write_layouts_config(keyboard, root):
>  
>      """
>  
> -    conf_dir = os.path.join(root, "/etc/X11/xorg.conf.d")
> +    conf_dir = os.path.normpath(root + "/etc/X11/xorg.conf.d")
>      conf_file = "01-anaconda-keyboard.conf"
>  
>      try:
> diff --git a/pyanaconda/kickstart.py b/pyanaconda/kickstart.py
> index 74a789d..89b0c0a 100644
> --- a/pyanaconda/kickstart.py
> +++ b/pyanaconda/kickstart.py
> @@ -1017,7 +1017,7 @@ class Timezone(commands.timezone.FC6_Timezone):
>          self.anaconda.timezone.setTimezoneInfo(self.timezone,
>          self.isUtc)
>          self.anaconda.dispatch.skip_steps("timezone")
>  
> -        chronyd_conf_path = os.path.join(ROOT_PATH,
> ntp.NTP_CONFIG_FILE)
> +        chronyd_conf_path = os.path.normpath(ROOT_PATH +
> ntp.NTP_CONFIG_FILE)
>          ntp.save_servers_to_config(self.ntp_servers,
>                                     conf_file_path=chronyd_conf_path)
>  
> --
> 1.7.4.4
> 
> _______________________________________________
> Anaconda-devel-list mailing list
> Anaconda-devel-list@xxxxxxxxxx
> https://www.redhat.com/mailman/listinfo/anaconda-devel-list
> 

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


[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux