diff --git a/gestion/locate-mac.py b/gestion/locate-mac.py index a7b9820f..32dc6ad8 100755 --- a/gestion/locate-mac.py +++ b/gestion/locate-mac.py @@ -7,8 +7,9 @@ from hptools import hpswitch from sys import argv for switch in ['backbone'] + all_switchs(): - prise = hpswitch(switch).where_is_mac(argv[1]) + sw = hpswitch(switch) + prise = sw.where_is_mac(argv[1]) if prise != None: - print "%-10s: %d" % (switch, prise) + print "%-10s: %d (%s)" % (switch, prise, sw.nom(None, prise)) else: print "%-10s: non trouvé" % switch