git.annexia.org
/
libguestfs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
33bc8fb
)
daemon/Win32: Windows replacement for umask.
author
Richard Jones
<rjones@redhat.com>
Wed, 25 Nov 2009 14:56:42 +0000
(14:56 +0000)
committer
Richard Jones
<rjones@redhat.com>
Wed, 25 Nov 2009 16:28:26 +0000
(16:28 +0000)
daemon/guestfsd.c
patch
|
blob
|
history
diff --git
a/daemon/guestfsd.c
b/daemon/guestfsd.c
index
64cf87f
..
40b3c2f
100644
(file)
--- a/
daemon/guestfsd.c
+++ b/
daemon/guestfsd.c
@@
-182,8
+182,16
@@
main (int argc, char *argv[])
setenv ("SHELL", "/bin/sh", 1);
setenv ("LC_ALL", "C", 1);
+#ifndef WIN32
/* We document that umask defaults to 022 (it should be this anyway). */
umask (022);
+#else
+ /* This is the default for Windows anyway. It's not even clear if
+ * Windows ever uses this -- the MSDN documentation for the function
+ * contains obvious errors.
+ */
+ _umask (0);
+#endif
/* Get the vmchannel string.
*