X-Recipient: archive-cygwin@delorie.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 Reply-To: brennan@sellner.org To: cygwin@cygwin.com Subject: Support for the TIOCINQ ioctl Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed 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@cygwin.com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Delivered-To: mailing list cygwin@cygwin.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