X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:reply-to:subject:to:references:from:message-id :date:mime-version:in-reply-to:content-type :content-transfer-encoding; q=dns; s=default; b=J5mv5JWJpcW4ypGS qufual96pqvdV9qCmgisKkzbcxDyiI4g/JBqvW85zmQ9GHKjpU7XcXbVllq9/sEh Y20mIka7lRYBni5ePhZqRtLYxwc+wRadKwOutcKGOdecRDH0lyK+hgWA2HdR7BQr V/mzrWcVa/ktEPtSfPaalKmAGJ8= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:reply-to:subject:to:references:from:message-id :date:mime-version:in-reply-to:content-type :content-transfer-encoding; s=default; bh=SHIolhIPRYdTJkSuFUWw12 ETFWE=; b=xI9Xdr3e9bOR9hTXbYpKfKha56pDjgVBDCCXATdKGIdFFt3OjfkZ24 pKulboE7mGOZEdlK4t4O/XCP3PRY3jxridodjRGOIV6JhmWCVtkB6h8MQ1kZ/4VO JeBPGMRvpkNcdOFAaC9ejp+Su7iG8YKNL12HeKd5Fg67SfuYTZ52w= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=0.8 required=5.0 tests=BAYES_50,SPF_PASS autolearn=ham version=3.3.2 spammy=donald, Donald, krieger, stdbuf X-HELO: mailsrv.cs.umass.edu Reply-To: moss AT cs DOT umass DOT edu Subject: Re: stdbuf does not work To: cygwin AT cygwin DOT com References: <1925552125 DOT 164706 DOT 1534595788839 DOT ref AT mail DOT yahoo DOT com> <1925552125 DOT 164706 DOT 1534595788839 AT mail DOT yahoo DOT com> From: Eliot Moss Message-ID: Date: Sat, 18 Aug 2018 09:14:10 -0400 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <1925552125.164706.1534595788839@mail.yahoo.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-IsSubscribed: yes On 8/18/2018 8:36 AM, Donald Krieger via cygwin wrote: > Dear list, > I require line buffered output from program1 and line buffered input to program2.The following works under Linux but not under Cygwin.   stdbuf -oL -eL program 1 |& program2 > > I've searched the archive without success.I have tried -o0 -e0 -i0 and have also tried >   stdbuf -oL -eL program1 |& stdbuf -i0 program2 > I have a fresh installation of cygwin as of a few months ago:  uname -a              yields:CYGWIN_NT-10.0 DESKTOP-S92525R 2.10.0(0.325/5/3) 2018-02-02 15:16 x86_64 Cygwin >   stdbuf --version    yields:stdbuf (GNU coreutils) 8.26Packaged by Cygwin (8.26-2)Copyright (C) 2016 Free Software Foundation, Inc.... Some thoughts to consider: - -i0 means unbuffered; did you write the wrong description above? - As noted in the strbuf man page, some programs don't use streams and thus are not affected by strbuf settings. I agree this is not something likely to change for the same program ported from Linux to Cygwin. - How do you have line endings set up on Cygwin or in any files you are processing? The usual Windows line ending being CR-LF instead of Linux's LF can confuse some programs. It might also help potential responders to know a little more about what program1 and program2 are. Are they Windows or Cygwin programs? Regards - EM -- 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