cygwin TEST: Add nagging debug output to pinfo

Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
This commit is contained in:
Corinna Vinschen 2017-04-24 17:35:06 +02:00
parent 5ef0399ddd
commit 7437d656cb
1 changed files with 13 additions and 0 deletions

View File

@ -319,6 +319,19 @@ pinfo::init (pid_t n, DWORD flag, HANDLE h0)
/* Fetching process info for /proc or ps? just ignore this one. */ /* Fetching process info for /proc or ps? just ignore this one. */
if (flag & PID_NOREDIR) if (flag & PID_NOREDIR)
break; 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. /* If not populated, wait 2 seconds for procinfo to become populated.
Would like to wait with finer granularity but that is not easily Would like to wait with finer granularity but that is not easily
doable. */ doable. */