]> code.ossystems Code Review - openembedded-core.git/commitdiff
oeqa/utils/qemurunner: fix wrong var in message
authorStefan Stanacar <stefanx.stanacar@intel.com>
Sun, 4 Aug 2013 09:15:40 +0000 (12:15 +0300)
committerSaul Wold <sgw@linux.intel.com>
Tue, 6 Aug 2013 06:59:56 +0000 (23:59 -0700)
If nothing matches we should print the text not
the match, else we get a nice traceback.

Changed in V2:
 - commit message

Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
meta/lib/oeqa/utils/qemurunner.py

index 45b3ccb789cf77537ea6cf88f8514a635e9f8c8e..d086203c04194b565b50e01081d107e6e9307e62 100644 (file)
@@ -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)