dlls/ntdll/tests/env.c -- fix uninitialized buffers (RESEND)

Zac Brown zac at zacbrown.org
Wed Nov 21 19:30:09 CST 2007


Hi,

Fixes valgrind error: 
	http://kegel.com/wine/valgrind/20071121/vg-ntdll_env.txt

Changelog: 
* Initialize buffers used in test using memset

--
Zac Brown <zac AT zacbrown DOT org>



---
 dlls/ntdll/tests/env.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/dlls/ntdll/tests/env.c b/dlls/ntdll/tests/env.c
index d822946..c72d5d0 100644
--- a/dlls/ntdll/tests/env.c
+++ b/dlls/ntdll/tests/env.c
@@ -89,6 +89,8 @@ static void testQuery(void)
 
     for (test = tests; test->var; test++)
     {
+	memset(bn, '\0', sizeof(bn));
+	memset(bv, '\0', sizeof(bv));
         name.Length = strlen(test->var) * 2;
         name.MaximumLength = name.Length + 2;
         name.Buffer = bn;
-- 
1.5.2.5




More information about the wine-patches mailing list