>From bbcbfb99656f5de9b8f9e42aa4fba0f733a11b54 Mon Sep 17 00:00:00 2001 From: Richard Jones Date: Wed, 25 Nov 2009 14:53:17 +0000 Subject: [PATCH 4/7] daemon/Win32: Replace setenv with Win32 equivalent. --- daemon/guestfsd.c | 7 +++++++ 1 files changed, 7 insertions(+), 0 deletions(-) diff --git a/daemon/guestfsd.c b/daemon/guestfsd.c index f31f1f2..64cf87f 100644 --- a/daemon/guestfsd.c +++ b/daemon/guestfsd.c @@ -20,6 +20,10 @@ #define _BSD_SOURCE /* for daemon(3) */ +#ifdef HAVE_WINDOWS_H +#include +#endif + #include #include #include @@ -167,6 +171,9 @@ main (int argc, char *argv[]) perror ("sigaction SIGPIPE"); /* but try to continue anyway ... */ #endif +#ifdef WIN32 +#define setenv(n,v,f) _putenv(n "=" v) +#endif /* Set up a basic environment. After we are called by /init the * environment is essentially empty. * https://bugzilla.redhat.com/show_bug.cgi?id=502074#c5 -- 1.6.5.2