On 11/24/2015 11:04 AM, marcandre.lureau@redhat.com wrote: > From: Marc-André Lureau > > This test exhibits a POSIX behaviour regarding switching between write > and read. It's undefined result if the application doesn't ensure a > flush between the two operations (with glibc, the flush can be implicit > when the buffer size is relatively small). The previous commit fixes > this test. > > Related to: > https://bugzilla.redhat.com/show_bug.cgi?id=1210246 > > Signed-off-by: Marc-André Lureau > --- > tests/test-qga.c | 95 ++++++++++++++++++++++++++++++++++++++++++++++++++++++-- > 1 file changed, 93 insertions(+), 2 deletions(-) > + > + /* seek to 0 */ > + cmd = g_strdup_printf("{'execute': 'guest-file-seek'," > + " 'arguments': { 'handle': %" PRId64 ", " > + " 'offset': %d, 'whence': %d } }", > + id, 0, SEEK_SET); If my patch goes in first, you'll want this to be s/SEEK_SET/0/ to match. (If yours goes in first, I'll spin a v2 of my patch to cover all sites in the testsuite that need munging). https://lists.gnu.org/archive/html/qemu-devel/2015-11/msg05454.html With that figured out, Reviewed-by: Eric Blake -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org