delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2000/04/27/21:02:02

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sourceware DOT cygnus DOT com>
List-Archive: <http://sourceware.cygnus.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sourceware DOT cygnus DOT com>
List-Help: <mailto:cygwin-help AT sourceware DOT cygnus DOT com>, <http://sourceware.cygnus.com/ml/#faqs>
Sender: cygwin-owner AT sourceware DOT cygnus DOT com
Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com
Message-ID: <20000428020201.27011.qmail@web124.yahoomail.com>
Date: Thu, 27 Apr 2000 19:02:01 -0700 (PDT)
From: Earnie Boyd <earnie_boyd AT yahoo DOT com>
Reply-To: earnie_boyd AT yahoo DOT com
Subject: Re: How is textmode/binmode determined in Cygwin 1.1.0 net release fo r pipes?
To: David Bolen <db3l AT fitlinxx DOT com>,
"'cygwin AT sourceware DOT cygnus DOT com'" <cygwin AT sourceware DOT cygnus DOT com>
MIME-Version: 1.0

The default mount mode for the 1.1.0 Net Relesae is binary mode.  This is a
change from the text mode of b20.1.  If your text files contain \r\n then you
need to do one of:

1) force the mounts back to text
2) tr -d '\r' < somefile > newsomefile && mv newsomefile somefile
3) find one of the dos to unix tools and build it to convert the files.

Earnie.
--- David Bolen <db3l AT fitlinxx DOT com> wrote:
> I just recently updated to the recent net release of 1.1.0, and immediately
> started running into some problems with my existing use of rsync, which
> generally disappeared if I reverted to the b20.1 version of cygwin1.dll I
> had previously been using.  I believe I tracked down the underlying cause,
> and have a possible workaround, but I was wondering if anyone could validate
> what I'm seeing and/or suggest a better solution.
> 
> The root problem appears to be that data being generated by rsync is
> somewhere along the line getting interpreted as if it was access to a
> "textmode" filesystem (LF -> CRLF).  I'm using rsync with pipes, so rsync is
> doing read()/write() to descriptors obtained via the pipe() call.  I don't
> seem to have the same problem with socket I/O, so it appears to be something
> specific to the file descriptors returned from pipe().
> 
> My current filesystem mount points are in textmode (I changed the default
> established by setup) since I'm stuck dealing with lots of files that still
> need handling with native NT stuff.  The tools I use either use O_BINARY (as
> rsync does for actual file access) or I can temporarily mount something
> binmode, so this hasn't been an issue.
> 
> I've found that adding CYGWIN=BINMODE to my enviornment seems to resolve the
> issue - my mount points still explicitly set textmode for file access, and
> it looks like the environment variable changed the default pipe handling.
> 
> Can anyone validate that the 1.1.0 release does in fact apply a
> textmode/binmode decision to pipe file descriptors?  Are there any other
> alternatives to setting CYGWIN to override this behavior?
> 
> Thanks for any information.
> 
> -- David
> 
> /-----------------------------------------------------------------------\
>  \               David Bolen            \   E-mail: db3l AT fitlinxx DOT com  /
>   |             FitLinxx, Inc.            \  Phone: (203) 708-5192    |
>  /  860 Canal Street, Stamford, CT  06902   \  Fax: (203) 316-5150     \
> \-----------------------------------------------------------------------/
> 
> 
> 
> --
> Want to unsubscribe from this list?
> Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com
> 

__________________________________________________
Do You Yahoo!?
Talk to your friends online and get email alerts with Yahoo! Messenger.
http://im.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