summaryrefslogtreecommitdiffstats
path: root/pty.c
diff options
context:
space:
mode:
authorKevin Steves <stevesk@pobox.com>2000-11-05 15:31:36 +0000
committerKevin Steves <stevesk@pobox.com>2000-11-05 15:31:36 +0000
commit85b3db6bcabfd6fd3fd97c871f4e29053a3338f3 (patch)
tree53885015c81e9c42d00057a03219c9cbb89d697b /pty.c
parent67e21e1eb2366f4598f8ee483dfbacc92010a687 (diff)
- (stevesk) pty.c: use __hpux to identify HP-UX.
Diffstat (limited to 'pty.c')
-rw-r--r--pty.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/pty.c b/pty.c
index 04004d20..cdf1d128 100644
--- a/pty.c
+++ b/pty.c
@@ -117,12 +117,15 @@ pty_allocate(int *ptyfd, int *ttyfd, char *namebuf, int namebuflen)
return 0;
}
#ifndef HAVE_CYGWIN
- /* Push the appropriate streams modules, as described in Solaris pts(7). */
+ /*
+ * Push the appropriate streams modules, as described in Solaris pts(7).
+ * HP-UX pts(7) doesn't have ttcompat module.
+ */
if (ioctl(*ttyfd, I_PUSH, "ptem") < 0)
error("ioctl I_PUSH ptem: %.100s", strerror(errno));
if (ioctl(*ttyfd, I_PUSH, "ldterm") < 0)
error("ioctl I_PUSH ldterm: %.100s", strerror(errno));
-#ifndef _HPUX_SOURCE
+#ifndef __hpux
if (ioctl(*ttyfd, I_PUSH, "ttcompat") < 0)
error("ioctl I_PUSH ttcompat: %.100s", strerror(errno));
#endif