about summary refs log tree commit diff
diff options
context:
space:
mode:
authorPeter Stephenson <pws@users.sourceforge.net>2001-05-08 10:26:58 +0000
committerPeter Stephenson <pws@users.sourceforge.net>2001-05-08 10:26:58 +0000
commit8ff0785863b5875fc10321b7da02a2ad3e7b76eb (patch)
tree32ee604e732ec0873aae868114774ea3a9d2588e
parentff82191c260160637ba67f0b4ecd4dd46778f53c (diff)
downloadzsh-8ff0785863b5875fc10321b7da02a2ad3e7b76eb.tar.gz
zsh-8ff0785863b5875fc10321b7da02a2ad3e7b76eb.tar.xz
zsh-8ff0785863b5875fc10321b7da02a2ad3e7b76eb.zip
Fixes from Andrej for zpty on cygwin
-rw-r--r--ChangeLog6
-rw-r--r--Src/Modules/zpty.c7
-rw-r--r--Test/comptest2
3 files changed, 13 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index f204d2e29..78e378a27 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2001-05-08  Peter Stephenson  <pws@csr.com>
+
+	* Andrej: 14248: Src/Modules/zpty.c, Test/comptest: don't use
+	O_NOCTTY in one case for zpty on cygwin, remove incorrect flag for
+	no blocking with zpty in comptest.
+
 2001-05-08  Sven Wischnowsky  <wischnow@zsh.org>
 
 	* 14252: Completion/Base/Core/_description, Doc/Zsh/compsys.yo:
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;
     }
diff --git a/Test/comptest b/Test/comptest
index 99867c5e3..c2cd74074 100644
--- a/Test/comptest
+++ b/Test/comptest
@@ -18,7 +18,7 @@ comptestinit () {
   (( OPTIND > 1 )) && shift $(( OPTIND - 1 ))
 
   export PS1="<PROMPT>"
-  zpty -b zsh "$comptest_zsh -f +Z"
+  zpty zsh "$comptest_zsh -f +Z"
 
   zpty -r zsh log1 "*<PROMPT>*" || { 
     print "first prompt hasn't appeared."