]> rtime.felk.cvut.cz Git - lisovros/qemu_apohw.git/commit
qemu-iotests: add poke_file utility function
authorStefan Hajnoczi <stefanha@redhat.com>
Tue, 6 Aug 2013 07:44:49 +0000 (15:44 +0800)
committerKevin Wolf <kwolf@redhat.com>
Tue, 6 Aug 2013 13:27:32 +0000 (15:27 +0200)
commit23ea2ecc2a43d850bc9482068201ece5da36a448
treef7b276806cef137b90bd0451f06a1dedffacff59
parente98768d43799cd3f00b358bfbe455fdae793d3e8
qemu-iotests: add poke_file utility function

The new poke_file function sets bytes at an offset in a file given a
printf-style format string.  It can be used to corrupt an image file for
test coverage of error paths.

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
tests/qemu-iotests/common.rc