This is the mail archive of the cygwin-patches 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]

fcntl debug


In an attempt to figure out why my third newlib freopen(NULL) patch
still failed (and hence leading to today's fourth patch - man, I have
really fat-fingered my efforts to get freopen(NULL) usable), I noticed
that an strace of fcntl(F_GETFL) was not as helpful as I would like.

2006-03-22  Eric Blake  <ebb9@byu.net>

	* fhandler.cc (fcntl): Print flags in hex.

Index: winsup/cygwin/fhandler.cc
===================================================================
RCS file: /cvs/src/src/winsup/cygwin/fhandler.cc,v
retrieving revision 1.250
diff -u -r1.250 fhandler.cc
--- winsup/cygwin/fhandler.cc	22 Feb 2006 16:40:42 -0000	1.250
+++ winsup/cygwin/fhandler.cc	22 Mar 2006 15:05:08 -0000
@@ -1,7 +1,7 @@
 /* fhandler.cc.  See console.cc for fhandler_console functions.
 
    Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-   2005 Red Hat, Inc.
+   2005, 2006 Red Hat, Inc.
 
 This file is part of Cygwin.
 
@@ -1304,7 +1304,7 @@
       break;
     case F_GETFL:
       res = get_flags ();
-      debug_printf ("GETFL: %d", res);
+      debug_printf ("GETFL: %p", res);
       break;
     case F_SETFL:
       {



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