tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[PATCH] fix errno for TIOCGETA ioctl



tcgetattr(</dev/null>) reports EOPNOTSUPP instead of ENOTTY.
---
 sys/dev/mm.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/sys/dev/mm.c b/sys/dev/mm.c
index dd83f17..3c93164 100644
--- a/sys/dev/mm.c
+++ b/sys/dev/mm.c
@@ -59,6 +59,7 @@ mmioctl(dev_t dev, u_long cmd, void *data, int flag,
                        return 0;
                case FIOSETOWN:
                case FIOGETOWN:
+               case TIOCGETA:  /* if we try detect tty here */
                case TIOCGPGRP:
                case TIOCSPGRP:
                        return ENOTTY;
-- 
1.5.2.5



Home | Main Index | Thread Index | Old Index