This is the mail archive of the
cygwin-cvs@cygwin.com
mailing list for the Cygwin project.
[newlib-cygwin] cygwin TEST: Add nagging debug output to pinfo
- From: Corinna Vinschen <corinna at sourceware dot org>
- To: cygwin-cvs at sourceware dot org
- Date: 24 Apr 2017 15:37:08 -0000
- Subject: [newlib-cygwin] cygwin TEST: Add nagging debug output to pinfo
https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;h=7437d656cbcd14c14f5f6428f51826665a4d5953
commit 7437d656cbcd14c14f5f6428f51826665a4d5953
Author: Corinna Vinschen <corinna@vinschen.de>
Date: Mon Apr 24 17:35:06 2017 +0200
cygwin TEST: Add nagging debug output to pinfo
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
Diff:
---
winsup/cygwin/pinfo.cc | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/winsup/cygwin/pinfo.cc b/winsup/cygwin/pinfo.cc
index f5a659d..a504828 100644
--- a/winsup/cygwin/pinfo.cc
+++ b/winsup/cygwin/pinfo.cc
@@ -319,6 +319,19 @@ pinfo::init (pid_t n, DWORD flag, HANDLE h0)
/* Fetching process info for /proc or ps? just ignore this one. */
if (flag & PID_NOREDIR)
break;
+ /* FIXME: Do we ever hit this case? And if so, in what situation? */
+ system_printf ("This shouldn't happen:\n"
+ " me: (%d, %d, %d, %W)\n"
+ " pid %d\n"
+ " process_state %y\n"
+ " cygstarted %d\n"
+ " dwProcessId %d\n"
+ " name %W",
+ myself->pid, myself->dwProcessId, myself->cygstarted,
+ myself->progname,
+ procinfo->pid, procinfo->process_state,
+ procinfo->cygstarted, procinfo->dwProcessId,
+ procinfo->progname);
/* If not populated, wait 2 seconds for procinfo to become populated.
Would like to wait with finer granularity but that is not easily
doable. */