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

Re: [virt-tools-list] [PATCH 1/1] Strip whitespace from remote hostname



On 02/26/2013 08:51 PM, Dave Allan wrote:
> If users accidentally add whitespace to the beginning or end of a hostname their connection will fail, so strip it.
> 
> Fixes BZ 818438 - Whitespace in remote connection hostname field is not trimmed
> ---
>  src/virtManager/connect.py | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/src/virtManager/connect.py b/src/virtManager/connect.py
> index d694477..f3fa95a 100644
> --- a/src/virtManager/connect.py
> +++ b/src/virtManager/connect.py
> @@ -306,7 +306,7 @@ class vmmConnect(vmmGObjectUI):
>      def generate_uri(self):
>          hv = self.widget("hypervisor").get_active()
>          conn = self.widget("connection").get_active()
> -        host = self.widget("hostname").child.get_text()
> +        host = self.widget("hostname").child.get_text().strip()
>          user = self.widget("username-entry").get_text()
>          is_remote = self.is_remote()
> 

Thanks Dave, pushed now.

- Cole


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