www.delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
X-Spam-Check-By: | sourceware.org |
X-Authority-Analysis: | v=1.0 c=1 a=yS73FzV6hpsA:10 a=l7Ot-VC3hIkA:10 a=w_pzkKWiAAAA:8 a=xe8BsctaAAAA:8 a=iF94Fn31S3ZVkHdLrQEA:9 a=V8zX6rHdxK5gUlXITs_eL7nyeZIA:4 a=eDFNAWYWrCwA:10 a=rPt6xJ-oxjAA:10 |
Message-ID: | <4805EFCF.3030103@byu.net> |
Date: | Wed, 16 Apr 2008 06:23:43 -0600 |
From: | Eric Blake <ebb9 AT byu DOT net> |
User-Agent: | Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.12) Gecko/20080213 Thunderbird/2.0.0.12 Mnenhy/0.7.5.666 |
MIME-Version: | 1.0 |
To: | cygwin AT cygwin DOT com, smr xxxx <smrxxxx AT gmail DOT com> |
Subject: | Re: Tail not reading to end of input |
References: | <18310f490804141056y466fa051x4240d2a52d3286a9 AT mail DOT gmail DOT com> |
In-Reply-To: | <18310f490804141056y466fa051x4240d2a52d3286a9@mail.gmail.com> |
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 |
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 According to smr xxxx on 4/14/2008 11:56 AM: | Hi, I've just rebuilt my machine and done a clean install of the | latest Cygwin, and am having a problem with tail. I'm wanting to know | whether this is a known issue before digging deeper. Not known to me, but I (thankfully) don't use Vista. | | When running a command such as "dir /s /a cygwin | tail -2" (from C:\) Is this in cmd.exe or a cygwin shell? At any rate, you haven't followed directions by posting 'cygcheck -svr' output as a text attachment, which might provide us more insight into your setup. | Problem reports: http://cygwin.com/problems.html | | If I first redirect the output of the dir command to a file and tail | that then all is well. Even running "type filename | tail -2" works. | Also, if I dos2unix the stream inplace (ie. "dir /s /a cygwin | | dos2unix | tail -2") it works correctly. Note that I installed with | Unix file type (as always). Unix file mode during cygwin's installation only affects regular files, not pipes. I don't know if the CR's being generated by the non-cygwin tools are interfering with tail, but tail attempts to always operate in binary mode, so I don't see how this could be broken. | 1. S_ISREG (stats.st_mode) returns 0 on XP, but 1 on Vista (I | haven't yet determined if this is an Enterprise-only or an SP1-only | issue) | 2. lseek() fails on XP, but succeeds on Vista. The SEEK_CUR below Are you sure this is on the same type of file? You can't lseek on pipes, and pipes are not regular files. So maybe there is some sort of issue where piped stdin inherited from a non-cygwin process on Vista wrongly looks like a regular file instead of a pipe, causing confusion within cygwin1.dll? - -- Don't work too hard, make some time for fun as well! Eric Blake ebb9 AT byu DOT net -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (Cygwin) Comment: Public key at home.comcast.net/~ericblake/eblake.gpg Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iEYEARECAAYFAkgF788ACgkQ84KuGfSFAYDSxQCgyo0/xK1ItHDLlXDHb/FfkNMO aPgAn2p/aBYhh+WJdrvJzmMIfhXpagFP =iGyp -----END PGP SIGNATURE----- -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |