Patchwork [04/20] qemu-iotests: Fix _filter_qemu

login
register
mail settings
Submitter Kevin Wolf
Date April 22, 2013, 11:31 a.m.
Message ID <1366630294-18984-5-git-send-email-kwolf@redhat.com>
Download mbox | patch
Permalink /patch/238464/
State New
Headers show

Comments

Kevin Wolf - April 22, 2013, 11:31 a.m.
$QEMU_PROG happens to be 'qemu' in my setup, so this sed command
replaces a bit too much. Restrict it to the start of the line and to
when it's followed by a colon, i.e. the form used by error messages.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
---
 tests/qemu-iotests/common.filter | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch

diff --git a/tests/qemu-iotests/common.filter b/tests/qemu-iotests/common.filter
index bc5f250..dcf6391 100644
--- a/tests/qemu-iotests/common.filter
+++ b/tests/qemu-iotests/common.filter
@@ -155,7 +155,7 @@  _filter_qemu_io()
 # replace occurrences of QEMU_PROG with "qemu"
 _filter_qemu()
 {
-    sed -e "s#$(basename $QEMU_PROG)#QEMU_PROG#g"
+    sed -e "s#^$(basename $QEMU_PROG):#QEMU_PROG:#"
 }
 
 # make sure this script returns success