Article View: gnu.gcc.bug
Article #445Possible ioctl bug?
From: David Olix
Date: Sun, 09 Jul 1989 22:33
Date: Sun, 09 Jul 1989 22:33
29 lines
929 bytes
929 bytes
Compiler: gcc 1.35
Machine: VAX 11/750
OS: Unix 4.3 BSD
Problem: ioctl function call returns error
Program: test.c
#include <sys/ioctl.h>
struct sgttyb arg;
void main()
{
if (ioctl(0, TIOCGETP, &arg) < 0)
perror("ioctl");
}
Compiled with:
gcc -g -o test test.c
Output:
ioctl: Inappropriate ioctl for device
I don't know if this a problem with gcc or what, but when I compile the
same program using cc, there is no output (as expected). Any help would
be useful. Please respond via e-mail
TIA,
--David Olix (dwho@nmtsun.nmt.edu)
Technical Details
Message-ID:
<2835@nmtsun.nmt.edu>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!ucsd!nmtsun!dwhoShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!ucsd!nmtsun!dwho From: dwho@nmtsun.nmt.edu (David Olix) Newsgroups: gnu.gcc.bug Subject: Possible ioctl bug? Keywords: ioctl Message-ID: <2835@nmtsun.nmt.edu> Date: 9 Jul 89 22:33:18 GMT Reply-To: dwho@titan.nmt.edu (David Olix) Organization: New Mexico Tech, Socorro NM Lines: 29