summaryrefslogtreecommitdiffstats
path: root/winsup/utils/ssp.c
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2008-09-12 22:43:10 +0000
committerChristopher Faylor <me@cgf.cx>2008-09-12 22:43:10 +0000
commita35d9f1a676f430e1dbbb555f327cd7a40df37f7 (patch)
treebb400cd789df6f8d154be4fca3e1aab9e59e3549 /winsup/utils/ssp.c
parent175742d8c818ff31b06174494a77b30e5008eb83 (diff)
downloadcygnal-a35d9f1a676f430e1dbbb555f327cd7a40df37f7.tar.gz
cygnal-a35d9f1a676f430e1dbbb555f327cd7a40df37f7.tar.bz2
cygnal-a35d9f1a676f430e1dbbb555f327cd7a40df37f7.zip
* cygcheck.cc (pathlike::check_existence): Remove class name from declaration.
(display_internet_error): Use proper format specifier for DWORD. (environ): Remove unneeded declaration. (main): Use brace around nested if to avoid an overly-helpful compiler warning. * dump_setup.cc (parse_filename): Reorganize nested if to avoid an overly-helpful compiler warning. * path.cc (GUID_shortcut): Use braces around part of initializer which needs them. (conv_fstab_spaces): Parenthesize assignment in while loop to avoid a compiler warning. (struct opt): Make static. * ps.cc (main): Reorganize nested if to avoid an overly-helpful compiler warning. * regtool.cc: Make some anonymous structs static to avoid a compiler warning. * ssp.c (lookup_thread_id): Initialize *tix to zero to avoid potential uninitialized use. * strace.cc (add_child): Use proper format specifier for DWORD. (remove_child): Ditto. (proc_child): Ditto.
Diffstat (limited to 'winsup/utils/ssp.c')
-rw-r--r--winsup/utils/ssp.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/winsup/utils/ssp.c b/winsup/utils/ssp.c
index 6d81ddb63..c7370d94d 100644
--- a/winsup/utils/ssp.c
+++ b/winsup/utils/ssp.c
@@ -161,10 +161,12 @@ static HANDLE
lookup_thread_id (DWORD threadId, int *tix)
{
int i;
+ *tix = 0;
for (i=0; i<num_active_threads; i++)
if (active_thread_ids[i] == threadId)
{
- if (tix) *tix = i;
+ if (tix)
+ *tix = i;
return active_threads[i];
}
return 0;