Skip to contentSkip to conversation

oeqa/utils/qemurunner: fix wrong var in message

PATCH New Stefan Stanacar 1 participant 1 message Aug 4, 2013

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 oeqa/utils/qemurunner: fix wrong var in message

If nothing matches we should print the text not
the match, else we get a nice traceback.

Changed in V2:
- commit message

---
 meta/lib/oeqa/utils/qemurunner.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/lib/oeqa/utils/qemurunner.py +1 -1
index 45b3ccb..d086203 100644
@@ -74,7 +74,7 @@ class QemuRunner:
                 console.write("root\n")
                 (index, match, text) = console.expect([r"(root@[\w-]+:~#)"],10)
                 if not match:
-                    bb.note("Couldn't get prompt, all I got was:\n%s" % match.group(0))
+                    bb.note("Couldn't get prompt, all I got was:\n%s" % text)
                     return False
                 console.write("ip addr show `ip route list | sed -n '1p' | awk '{print $5}'` | sed -n '3p' | awk '{ print $2 }' | cut -f 1 -d \"/\"\n")
                 (index, match, text) = console.expect([r"((?:[0-9]{1,3}\.){3}[0-9]{1,3})"],10)
Signature · 1 line
1.8.3.1