summary refs log tree commit diff
path: root/Src
diff options
context:
space:
mode:
Diffstat (limited to 'Src')
-rw-r--r--Src/Modules/zpty.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/Src/Modules/zpty.c b/Src/Modules/zpty.c
index c69aa4e97..80deba786 100644
--- a/Src/Modules/zpty.c
+++ b/Src/Modules/zpty.c
@@ -183,7 +183,12 @@ get_pty(int master, int *retfd)
 
 	return 0;
     }
-    if ((sfd = open(name, O_RDWR|O_NOCTTY)) < 0) {
+    if ((sfd = open(name, O_RDWR
+#ifndef __CYGWIN__
+		    /* It is not clear whether this flag is actually needed. */
+		    |O_NOCTTY
+#endif
+	)) < 0) {
 	close(mfd);
 	return 1;
     }