Fix for <http://rsync.samba.org/cgi-bin/rsync/incoming?id=3750>
authorMartin Pool <mbp@samba.org>
Mon, 14 Jan 2002 00:16:51 +0000 (00:16 +0000)
committerMartin Pool <mbp@samba.org>
Mon, 14 Jan 2002 00:16:51 +0000 (00:16 +0000)
temp files must be opened through do_open so that binary modes is used
on cygwin.  (Chris Boucher)

syscall.c

index a56eb79..dbac7dc 100644 (file)
--- a/syscall.c
+++ b/syscall.c
@@ -132,7 +132,7 @@ int do_mkstemp(char *template, mode_t perms)
        }
 #else
        if (!mktemp(template)) return -1;
-       return open(template, O_RDWR|O_EXCL|O_CREAT, perms);
+       return do_open(template, O_RDWR|O_EXCL|O_CREAT, perms);
 #endif
 }