[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen-unstable] libxenlight: typo in old patch, lead to waitpid forever instead of



# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1263279886 0
# Node ID 9f4c6b96bd7ffeea956d5b6467e78b57264dbd1e
# Parent  6ae90d7f7f45cdb578c26fc8ee5f3997f8e0ba5e
libxenlight: typo in old patch, lead to waitpid forever instead of
waitpid with WNOHANG

fixes qemu starting problem

Signed-off-by: Vincent Hanquez <vincent.hanquez@xxxxxxxxxxxxx>
---
 tools/libxl/libxl_exec.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff -r 6ae90d7f7f45 -r 9f4c6b96bd7f tools/libxl/libxl_exec.c
--- a/tools/libxl/libxl_exec.c  Tue Jan 12 07:03:54 2010 +0000
+++ b/tools/libxl/libxl_exec.c  Tue Jan 12 07:04:46 2010 +0000
@@ -45,7 +45,7 @@ static pid_t libxl_fork(struct libxl_ctx
 
 static int call_waitpid(pid_t (*waitpid_cb)(pid_t, int *, int), pid_t pid, int 
*status, int options)
 {
-    return (waitpid_cb) ? waitpid_cb(pid, status, 0) : waitpid(pid, status, 0);
+    return (waitpid_cb) ? waitpid_cb(pid, status, options) : waitpid(pid, 
status, options);
 }
 
 void libxl_exec(struct libxl_ctx *ctx, int stdinfd, int stdoutfd, int stderrfd,
@@ -202,7 +202,7 @@ int libxl_spawn_check(struct libxl_ctx *
     if (!for_spawn) return 0;
 
     assert(for_spawn->intermediate);
-    got = call_waitpid(ctx->waitpid_instead, for_spawn->intermediate, &status, 
0);
+    got = call_waitpid(ctx->waitpid_instead, for_spawn->intermediate, &status, 
WNOHANG);
     if (!got) return 0;
 
     assert(got == for_spawn->intermediate);

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.