delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2011/12/09/15:45:16

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=3.5 required=5.0 tests=AWL,BAYES_00,BOTNET,RCVD_IN_DNSWL_NONE
X-Spam-Check-By: sourceware.org
Message-id: <4EE27335.9070106@cygwin.com>
Date: Fri, 09 Dec 2011 15:44:37 -0500
From: "Larry Hall (Cygwin)" <reply-to-list-only-lh AT cygwin DOT com>
Reply-to: cygwin AT cygwin DOT com
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:8.0) Gecko/20111105 Thunderbird/8.0
MIME-version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: stdout output missing, but redirecting works
References: <CAGVbXL7pXn5BZSNXNJKMTbGUOQzAhGBOZwxdsPGa-bucQf6dBg AT mail DOT gmail DOT com>
In-reply-to: <CAGVbXL7pXn5BZSNXNJKMTbGUOQzAhGBOZwxdsPGa-bucQf6dBg@mail.gmail.com>
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

On 12/9/2011 2:47 PM, Brian Craft wrote:
> I compiled a program yesterday which output some lines to stdout. It
> appeared to be working. Running it today, I get nothing on stdout.
> However, if I redirect stdout to a file, the correct output appears in
> the file. E.g.
>
> # no output
> ./foo
> # "hello world" in bar
> ./foo>  bar
>
>
> In between yesterday and today, I've rebooted and run rebaseall, so
> perhaps one of those is responsible for the change.
>
> Any suggestions?

Sounds like buffering to me.  Is this program compiled with Cygwin's gcc
or something else?  What kind of terminal are you running it in?  Same one
as yesterday?

-- 
Larry

_____________________________________________________________________

A: Yes.
 > Q: Are you sure?
 >> A: Because it reverses the logical flow of conversation.
 >>> Q: Why is top posting annoying in email?

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

- Raw text -


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