public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: "Phan, Linh H (3443)" <Linh.H.Phan@jpl.nasa.gov>
To: "cygwin@cygwin.com" <cygwin@cygwin.com>
Subject: stderr doesn't work in gdb?
Date: Sat, 05 Nov 2011 20:03:00 -0000	[thread overview]
Message-ID: <79D001DEDB0DEC47A247B110F3E866820D07BA475D@ALTPHYEMBEVSP30.RES.AD.JPL> (raw)

Hi,

  it seems there is a problem with stderr when running a program under gdb in cygwin 1.7.9 with 64 bit Windows 7; eg, if I run this program:

#include <stdio.h>
main()
{
  fprintf(stderr,"stderr does not print out.\n");
  fprintf(stdout,"Only stdout does print out.\n");
}

(gdb) r
Only stdout does print out.


The program works fine outside of gdb; ie, stderr does work when not running in gdb.
Does anyone know a fix for this?

Thank you,

Linh
PS  This my version of cygwin:
CYGWIN_NT-6.1-WOW64 LMC-022482 1.7.9(0.237/5/3) 2011-03-29 10:10 i686 Cygwin

and gdb:
GNU gdb (GDB) 7.3.50.20110821-cvs (cygwin-special)

I also tested under:
GNU gdb 6.8.0.20080328-cvs (cygwin-special)
on the same cygwin 1.7.9 on 64 bit Windows7 and the same stderr problem exist.

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

             reply	other threads:[~2011-11-05 20:03 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-05 20:03 Phan, Linh H (3443) [this message]
2011-11-05 21:29 ` Ryan Johnson
2011-11-05 22:32 ` Phan, Linh H (3443)
2011-11-05 23:21   ` Mark Geisert

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=79D001DEDB0DEC47A247B110F3E866820D07BA475D@ALTPHYEMBEVSP30.RES.AD.JPL \
    --to=linh.h.phan@jpl.nasa.gov \
    --cc=cygwin@cygwin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).