public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] qemu-kvm: compatfd: trivial compile fix
@ 2009-12-15  1:05 Chris Wright
  2009-12-15  9:40 ` Avi Kivity
  0 siblings, 1 reply; 2+ messages in thread
From: Chris Wright @ 2009-12-15  1:05 UTC (permalink / raw)
  To: kvm; +Cc: Avi Kivity, Marcelo Tosatti

Fix build when !CONFIG_EVENTFD

 CC    compatfd.o
compatfd.c: In function ‘qemu_eventfd’:
compatfd.c:137: error: ‘ret’ undeclared (first use in this function)
compatfd.c:137: error: (Each undeclared identifier is reported only once
compatfd.c:137: error: for each function it appears in.)
make: *** [compatfd.o] Error 1

Signed-off-by: Chris Wright <chrisw@redhat.com>
---
 compatfd.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/compatfd.c b/compatfd.c
index e87bb9e..4a00d95 100644
--- a/compatfd.c
+++ b/compatfd.c
@@ -118,9 +118,9 @@ int qemu_signalfd(const sigset_t *mask)
 
 int qemu_eventfd(int *fds)
 {
-#if defined(CONFIG_EVENTFD)
     int ret;
 
+#if defined(CONFIG_EVENTFD)
     ret = syscall(SYS_eventfd, 0);
     if (ret >= 0) {
         fds[0] = ret;

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] qemu-kvm: compatfd: trivial compile fix
  2009-12-15  1:05 [PATCH] qemu-kvm: compatfd: trivial compile fix Chris Wright
@ 2009-12-15  9:40 ` Avi Kivity
  0 siblings, 0 replies; 2+ messages in thread
From: Avi Kivity @ 2009-12-15  9:40 UTC (permalink / raw)
  To: Chris Wright; +Cc: kvm, Marcelo Tosatti

On 12/15/2009 03:05 AM, Chris Wright wrote:
> Fix build when !CONFIG_EVENTFD
>
>   CC    compatfd.o
> compatfd.c: In function ‘qemu_eventfd’:
> compatfd.c:137: error: ‘ret’ undeclared (first use in this function)
> compatfd.c:137: error: (Each undeclared identifier is reported only once
> compatfd.c:137: error: for each function it appears in.)
> make: *** [compatfd.o] Error 1
>
>    

Applied, thanks.

-- 
error compiling committee.c: too many arguments to function


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-12-15  9:40 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-15  1:05 [PATCH] qemu-kvm: compatfd: trivial compile fix Chris Wright
2009-12-15  9:40 ` Avi Kivity

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox