This is the mail archive of the cygwin-patches mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: fhandler_tty_slave::tcflush() in fhandler_tty.cc


----Original Message----
>From: Vaclav Haisman
>Sent: 05 August 2005 14:01

> fhandler_tty_slave::tcflush() is IMHO still wrong. The result of
> comparison is bool and bool converted to int is either 1 or 0. The
> following patch should cure it.

  Just to enlarge upon that, the problem is not just that it's returning a
zero-or-one when it should be returning a zero-or-minus-one result, but that
the logical sense is inverted too: when flushing input, the test means that
it used to return zero for failure and non-zero for success.  Your patch
looks good to me.


    cheers,
      DaveK
-- 
Can't think of a witty .sigline today....


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]