WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-bugs

[Xen-bugs] [Bug 231] New: choose_vnc_display deals poorly with IPv6 nets

To: xen-bugs@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-bugs] [Bug 231] New: choose_vnc_display deals poorly with IPv6 netstat output
From: bugzilla-daemon@xxxxxxxxxxxxxxxxxxx
Date: Thu, 15 Sep 2005 04:53:52 +0000
Delivery-date: Thu, 15 Sep 2005 04:53:56 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-bugs-request@lists.xensource.com?subject=help>
List-id: Xen Bugzilla <xen-bugs.lists.xensource.com>
List-post: <mailto:xen-bugs@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-bugs>, <mailto:xen-bugs-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-bugs>, <mailto:xen-bugs-request@lists.xensource.com?subject=unsubscribe>
Reply-to: bugs@xxxxxxxxxxxxxxxxxx
Sender: xen-bugs-bounces@xxxxxxxxxxxxxxxxxxx
http://bugzilla.xensource.com/bugzilla/show_bug.cgi?id=231

           Summary: choose_vnc_display deals poorly with IPv6 netstat output
           Product: Xen
           Version: unstable
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Tools
        AssignedTo: xen-bugs@xxxxxxxxxxxxxxxxxxx
        ReportedBy: nickolai@xxxxxxxxxxxxxxx


The choose_vnc_display function in create.py deals poorly with IPv6-style 
netstat output, e.g. when the ipv6 module is loaded, because IPv6 addresses 
contain colons.

This simple patch fixes the problem:

diff -r bd477fcd32ab tools/python/xen/xm/create.py
--- a/tools/python/xen/xm/create.py     Thu Sep 15 04:12:54 2005
+++ b/tools/python/xen/xm/create.py     Wed Sep 14 21:50:27 2005
@@ -673,8 +673,9 @@
             # Local port is field 3.
             y = x.split()[3]
             # Field is addr:port, split off the port.
-            y = y.split(':')[1]
-            r.append(int(y))
+            y = y.split(':')
+            z = y[len(y) - 1]
+            r.append(int(z))
         return r

     ports = netstat_local_ports()

-- 
Configure bugmail: 
http://bugzilla.xensource.com/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

_______________________________________________
Xen-bugs mailing list
Xen-bugs@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-bugs

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-bugs] [Bug 231] New: choose_vnc_display deals poorly with IPv6 netstat output, bugzilla-daemon <=