diff options
author | Pavel Fedin <p.fedin@samsung.com> | 2015-07-01 10:18:11 +0300 |
---|---|---|
committer | Pádraig Brady <P@draigBrady.com> | 2015-07-01 10:10:12 +0100 |
commit | 9ba6a0085c72902f8ac30e4378db54fe7f2ff7d6 (patch) | |
tree | 0afcf00d559b1263572eeda6b018423dec6387b2 /lib | |
parent | 716083c1a8ea4580e09d35f96b67f8bd875c0fe3 (diff) | |
download | gnulib-9ba6a0085c72902f8ac30e4378db54fe7f2ff7d6.tar.gz |
fix pty related tests issues on Windows
* lib/grantpt.c (grantpt): grantpt.c seems to be never used on Windows,
however it's still present in tests/ subdirectory of the final project.
Therefore avoid it to pass `make check`.
* tests/test-openpty.c (main): Windows has no PTYs and gnulib's openpty()
will just return -ENOSYS, so avoid this non applicable test allowing
the build to proceed.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/grantpt.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/grantpt.c b/lib/grantpt.c index a740091bad..1a48645c56 100644 --- a/lib/grantpt.c +++ b/lib/grantpt.c @@ -46,9 +46,10 @@ int grantpt (int fd) { -#if defined __OpenBSD__ +#if defined __OpenBSD__ || defined _WIN32 /* On OpenBSD, master and slave of a pseudo-terminal are allocated together, - through an ioctl on /dev/ptm. There is no need for grantpt(). */ + through an ioctl on /dev/ptm. On Windows there are no ptys. + Therefore in either case there is no need for grantpt(). */ return 0; #else /* This function is most often called from a process without 'root' |