delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2010/08/27/18:32:18

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=0.1 required=5.0 tests=AWL,BAYES_00,T_RP_MATCHES_RCVD
X-Spam-Check-By: sourceware.org
Date: Fri, 27 Aug 2010 18:31:58 -0400 (EDT)
From: Brennan Peter Sellner <bsellner AT andrew DOT cmu DOT edu>
Reply-To: brennan AT sellner DOT org
To: cygwin AT cygwin DOT com
Subject: Support for the TIOCINQ ioctl
Message-ID: <Pine.LNX.4.64.1008271822560.25309@unix11.andrew.cmu.edu>
MIME-Version: 1.0
X-SMTP-Spam-Clean: 8% ( BODY_SIZE_1000_LESS 0, BODY_SIZE_2000_LESS 0, BODY_SIZE_5000_LESS 0, BODY_SIZE_600_699 0, BODY_SIZE_7000_LESS 0, TO_NO_NAME 0, __CP_URI_IN_BODY 0, __CT 0, __CT_TEXT_PLAIN 0, __HAS_MSGID 0, __MIME_TEXT_ONLY 0, __MIME_VERSION 0, __SANE_MSGID 0, __TO_MALFORMED_2 0, __URI_NO_MAILTO 0, __URI_NO_WWW 0, __URI_NS )
X-SMTP-Spam-Score: 8%
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

By any chance, has support for the TIOCINQ ioctl on file descriptors 
(used to check how many bytes of data are in the input buffer) been 
added to Cygwin?  It hadn't as of 2004:

   http://sourceware.org/ml/cygwin/2004-07/msg00910.html

...but I haven't found any newer references to it.  I'm inferring that 
it's not supported, as ioctl(fd, TIOCINQ, &available) (where fd is a valid 
file descriptor, and available is a long) fails, with errno set to 
'invalid argument'.  I'm running Cygwin 1.7.6 on Vista.

I'm hoping I'm missing something...  Is there an alternative way to check 
the number of bytes on an fd's input buffer in Cygwin?

Thanks,

-Brennan


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019