www.delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1999/07/29/09:53:58

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
Sender: cygwin-owner AT sourceware DOT cygnus DOT com
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT sourceware DOT cygnus DOT com>
List-Archive: <http://sourceware.cygnus.com/ml/cygwin/>
List-Help: <mailto:cygwin-help AT sourceware DOT cygnus DOT com>,
<http://sourceware.cygnus.com/ml/#faqs>
Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com
Message-ID: <19990729120856.18008.rocketmail@web109.yahoomail.com>
Date: Thu, 29 Jul 1999 05:08:56 -0700 (PDT)
From: Earnie Boyd <earnie_boyd AT yahoo DOT com>
Reply-To: earnie_boyd AT yahoo DOT com
Subject: RE: Cat and Head Problems with Binary Files
To: jtr AT mitre DOT org, cygwin AT sourceware DOT cygnus DOT com
MIME-Version: 1.0

--- Jeffry T Ross <jtr AT mitre DOT org> wrote:
> Randy
> 
> I thought the suggestion to use dd was a good, although a bit excessive
> when one only wants to move bytes from a file to a pipe without any
> conversion. So I tried it:
> 
> dd if=test1 > test2
> test1 was 1296 bytes and test2 became 1301 bytes.
> 
> So then I tried dd directly to a file.
> dd if=test1 of=test2
> this worked fine.
> 
> So now I don't suspect cat but the piping and redirection.
> The question is how does cygwin implement it's piping and redirection?
> Is this problem imposed by the underlying WIN/DOS or is it a bug in BASH?
> 
> The pipe shouldn't be trying to interpret the data going through it.
> That's the job of the process at the end of the pipe, be it the terminal
> or another program.
> 
> 
> 
> 							jtr AT mitre DOT org
>  
Hi Jeffry,

What version of cygwin1.dll are you using?  Supply the output of `uname -a' and
I'll know the answer to that.

The stock b20.1 version has a problem with the default behaviors of the 
[no]binary switch for the CYGWIN variable.  If you don't have at least the Jan
15th snapshot then go to the site or mirror and install that version.

The [no]binmode switch affect the processing mode (text vs binary) for pipes
and redirects.  The default is binmode which will pass the \r character through
the pipe and not add the \r character on the redirect.  However, the default
binmode and the specified binmode are different in the stock b20.1 version. 
This created some interesting results.

Good Luck,
===
Earnie Boyd <mailto:earnie_boyd AT yahoo DOT com>

Newbies, please visit
<http://www.freeyellow.com/members5/gw32/index.html>

(If you respond to the list, then please don't cc me)
_____________________________________________________________
Do You Yahoo!?
Free instant messaging and more at http://messenger.yahoo.com


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com

- Raw text -


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