Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2004-07-15 06:07:14 +0400
committerChristopher Faylor <me@cgf.cx>2004-07-15 06:07:14 +0400
commit839677149f6c598e9319495a2623a54d8ef9d2a5 (patch)
tree84c7d943c546282102829bd7068825bb0a656102 /winsup/cygwin/fhandler_registry.cc
parent8e47f4464b3a255ffa4dd7377ac1dfb9f892cec4 (diff)
* fhandler_registry.cc (registry_listing): Correct typo.
(fhandler_registry::fill_filebuf): Set size of newly expanded buffer prior to calling RegQueryValueEx.
Diffstat (limited to 'winsup/cygwin/fhandler_registry.cc')
-rw-r--r--winsup/cygwin/fhandler_registry.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/winsup/cygwin/fhandler_registry.cc b/winsup/cygwin/fhandler_registry.cc
index 95ee3ffd7..c15882176 100644
--- a/winsup/cygwin/fhandler_registry.cc
+++ b/winsup/cygwin/fhandler_registry.cc
@@ -48,7 +48,7 @@ static const char *registry_listing[] =
"HKEY_LOCAL_MACHINE",
"HKEY_USERS",
"HKEY_DYN_DATA", // 95/98/Me
- "HKEY_PERFOMANCE_DATA", // NT/2000/XP
+ "HKEY_PERFORMANCE_DATA", // NT/2000/XP
NULL
};
@@ -575,6 +575,7 @@ fhandler_registry::fill_filebuf ()
{
bufalloc += 1000;
filebuf = (char *) realloc (filebuf, bufalloc);
+ size = bufalloc;
error = RegQueryValueEx (handle, value_name, NULL, &type,
(BYTE *) filebuf, &size);
if (error != ERROR_SUCCESS && error != ERROR_MORE_DATA)