From 45b035c79e269bbf8f4f6d8b6b1b592aad5e8cf7 Mon Sep 17 00:00:00 2001 Message-Id: <45b035c79e269bbf8f4f6d8b6b1b592aad5e8cf7.1367947969.git.minovotn@redhat.com> In-Reply-To: <707b9b97153063374d2530e72c49b1499fc21af9.1367947969.git.minovotn@redhat.com> References: <707b9b97153063374d2530e72c49b1499fc21af9.1367947969.git.minovotn@redhat.com> From: Michal Novotny Date: Tue, 7 May 2013 18:37:22 +0200 Subject: [PATCH 030/114] Revert "qemu-ga: Drop pointless lseek() from ga_open_pidfile()" This reverts commit 5d431478605fd588717012e11aa9005212cf4a8e. Reverting as asked by Laszlo in message <51892739.2030807@redhat.com> because of the ordering issue (most likely) related to supersed testing. Signed-off-by: Michal Novotny --- qemu-ga.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qemu-ga.c b/qemu-ga.c index f8f6ac4..eb7fc7a 100644 --- a/qemu-ga.c +++ b/qemu-ga.c @@ -289,7 +289,7 @@ static bool ga_open_pidfile(const char *pidfile) return false; } - if (ftruncate(pidfd, 0)) { + if (ftruncate(pidfd, 0) || lseek(pidfd, 0, SEEK_SET)) { g_critical("Failed to truncate pid file"); goto fail; } -- 1.7.11.7