This is the mail archive of the
mailing list for the Cygwin project.
Re: text / binary mounts (sorry)
- To: "'cygwin at sourceware dot cygnus dot com'" <cygwin at sourceware dot cygnus dot com>
- Subject: Re: text / binary mounts (sorry)
- From: Chris Faylor <cgf at cygnus dot com>
- Date: Fri, 2 Jun 2000 21:45:30 -0400
- References: <1DB8BA4BAC88D3118B2300508B5A552CD92550@mail.fitlinxx.com>
- Reply-To: cygwin at sourceware dot cygnus dot com
On Fri, Jun 02, 2000 at 05:35:29PM -0400, David Bolen wrote:
>Earnie Boyd [email@example.com] writes:
>>Are you sure of this, Ron? AFAIK CYGWIN=binmode only affects the pipes
>>and redirection and not file I/O. BTW CYGWIN=binmode is the default.
>One minor caveat with respect to "default" - the default behavior for
>the stdin/stdout handles changed from b20.1 to the net releases,
>dependent on whether you explicitly had the environment variable or
>not. If you put CYGWIN=binmode in your environment it also affects
>stdin/stdout default behavior, but if you leave the variable out they
>will default to text mode and not binary.
It only affects stdin/stdout behavior when the program is run from the
Windows command shell.
>It's my understanding this was done for some issues with interactive
>tool use, but unfortunately it also comes into play when utilities
>fork() a copy of themselves to process data on stdin/stdout (I ran into
>this with the rsync utility).
I'm not sure how this could be. Reading the code, I see this line right
before the part that sets the stdin/stdout based on CYGWIN=binmode.
if (!parent_alive && NOTSTATE(myself, PID_CYGPARENT))
fork() is a cygwin function which produces an additional copy of a running
program. That means that the child has a a cygwin parent and so stdin should
be in the same state in the child as in the parent.
Want to unsubscribe from this list?
Send a message to firstname.lastname@example.org