This is the mail archive of the
mailing list for the Cygwin project.
Re: fhandler_serial fix
- From: Christopher Faylor <cgf at redhat dot com>
- To: cygwin-patches at cygwin dot com
- Date: Sun, 3 Nov 2002 23:10:23 -0500
- Subject: Re: fhandler_serial fix
- References: <006b01c283b1$b33bb580$0201a8c0@sos>
- Reply-to: cygwin-patches at cygwin dot com
On Sun, Nov 03, 2002 at 10:24:33PM -0500, Sergey Okhapkin wrote:
>The patch fixes a crash when ioctl(fd, TCFLSH, how) is called for a serial
>2002-11-03 Sergey Okhapkin <firstname.lastname@example.org>
> * fhandler_serial.cc (fhandler_serial::ioctl): the 3rd argument of
> ioctl(fd, TCFLSH, ...) is integer but not a pointer.
Thanks, but I don't think this is exactly the right solution for this
problem. I'd rather see the handling of all of the cmds grouped in
the switch statement.
This function needed a lot of work. There were some obvious typos (use
of a '|' where a '||' was intended) and a suspicious lack of errno
setting. I'm going to check in a reformatting of the function which
will hopefully address the above problem as well as these others.
I wasn't sure about a couple of the errnos. If you, or anyone has any
insight into what should be returned int the cases where I defaulted to
EINVAL, it would be appreciated.