This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [ANNOUNCEMENT] Updated: bash-4.3.39-2


On Thu, 24 Sep 2015 15:10:25 -0600
Eric Blake <...> wrote:
> On 06/04/2015 03:51 AM, Mikhail Usenko wrote:
> > Eric Blake (cygwin) <...> wrote:
> >> 4.3.39-2
> > 
> > Hello, Eric.
> > It has the same issue as in the previous version:
> > eating one \r from the odd numbered chains of the \r.
> > 
> 
> Please try the (currently-experimental) 4.3.42-4, which should fix the
> issues observed.
> 

On Thu, 24 Sep 2015 10:55:45 -0600
Eric Blake <...> wrote:
> 
> Jeff Downs helped me investigate off-list, and I think he found the
> culprit (a typo in input.c that requested O_TEXT when it meant B_TEXT,
> when mapping from open() flags to bash's internal B_* flags). I'm
> building a new bash build right now, and will shortly be posting it for
> testing.
> 


Hello, Eric.
Thank you for working on this annoying problem that stops
some parsing scripts (that worked in cygwin in 3-4 bash versions ago)
to work correctly and thereby so the cygwin/bash overall employing.
But catching that bug (in upstream?) hasn't changed anything
at least on my installation:

---%<---<cygwin-test.sh>---%<---
#! /bin/bash
bash -version | head -n1
echo

sender()
{
  echo -n  '\r\n' >&2
  echo -ne '\r\n'
  sleep 1
  echo -n  '\r\r\n' >&2
  echo -ne '\r\r\n'
  sleep 1
  echo -n  '\r\r\r\n' >&2
  echo -ne '\r\r\r\n'
  sleep 1
  echo -n  '\r\r\r\r\n' >&2
  echo -ne '\r\r\r\r\n'
  sleep 1
  echo -n  '\r\r\r\r\r\n' >&2
  echo -ne '\r\r\r\r\r\n'
  sleep 1
}

receiver()
{
  t=""
  while read t || [ "$t" ]; do
    echo -ne ": \t"
    od -A n -t x1  <<<"$t"
  done  >&2
}


# implicit pipe
receiver < <(sender)

# explicit pipeline
sender | receiver
--->%---<cygwin-test.sh>--->%---


$ ./cygwin-test.sh
GNU bash, version 4.3.42(4)-release (x86_64-unknown-cygwin)

\r\n:    0a
\r\r\n:          0d 0d 0a
\r\r\r\n:        0d 0d 0a
\r\r\r\r\n:      0d 0d 0d 0d 0a
\r\r\r\r\r\n:    0d 0d 0d 0d 0a
\r\n:    0a
\r\r\n:          0d 0d 0a
\r\r\r\n:        0d 0d 0a
\r\r\r\r\n:      0d 0d 0d 0d 0a
\r\r\r\r\r\n:    0d 0d 0d 0d 0a


-- 
Mike


--
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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]