From af5faf98c18a84cd213235511ac55199300c76f6 Mon Sep 17 00:00:00 2001
From: Mehdi Abaakouk <sileht@sileht.net>
Date: Fri, 20 Jul 2012 17:52:06 +0200
Subject: [PATCH] fix incorrect var name

---
 lg.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lg.py b/lg.py
index 3a0a1fc..0913317 100755
--- a/lg.py
+++ b/lg.py
@@ -382,7 +382,7 @@ def show_bgpmap():
 
             label_without_star = kwargs["label"].replace("*", "")
             labels = e.get_label().split("\r") 
-            if "%s*" % pl not in labels:
+            if "%s*" % label_without_star not in labels:
                 labels = [ kwargs["label"] ]  + [ l for l in labels if not l.startswith(label_without_star) ] 
                 labels = sorted(labels, cmp=lambda x,y: x.endswith("*") and -1 or 1)