summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin/hookapi.cc
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2011-02-09 15:46:00 +0000
committerChristopher Faylor <me@cgf.cx>2011-02-09 15:46:00 +0000
commit27239c637271a45793a12a85e66b366c37cbc28c (patch)
treee37359919520838301713f0e95e6d8d005cc64d2 /winsup/cygwin/hookapi.cc
parent7a5f322c35b2af993c803beb6f575732b143b12b (diff)
downloadcygnal-27239c637271a45793a12a85e66b366c37cbc28c.tar.gz
cygnal-27239c637271a45793a12a85e66b366c37cbc28c.tar.bz2
cygnal-27239c637271a45793a12a85e66b366c37cbc28c.zip
* hookapi.cc (hook_or_detect_cygwin): Prevent i from being considered
uninitialized by gcc.
Diffstat (limited to 'winsup/cygwin/hookapi.cc')
-rw-r--r--winsup/cygwin/hookapi.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/winsup/cygwin/hookapi.cc b/winsup/cygwin/hookapi.cc
index 7a13ee047..46df84701 100644
--- a/winsup/cygwin/hookapi.cc
+++ b/winsup/cygwin/hookapi.cc
@@ -252,7 +252,7 @@ hook_or_detect_cygwin (const char *name, const void *fn, WORD& subsys)
fh.origfn = NULL;
fh.hookfn = fn;
char *buf = (char *) alloca (strlen (name) + sizeof ("_64"));
- int i;
+ int i = 0;
// Iterate through each import descriptor, and redirect if appropriate
for (PIMAGE_IMPORT_DESCRIPTOR pd = pdfirst; pd->FirstThunk; pd++)
{