userenv: tests/userenv.c: fix buffer overrun

Dan Kegel dank at kegel.com
Tue Jun 3 15:07:23 CDT 2008


Found via valgrind.  Fixes

 Use of uninitialised value of size 4
    at wine_cp_mbstowcs (mbtowc.c:79)
    by MultiByteToWideChar (locale.c:1846)
    by CompareStringA (locale.c:2722)
    by get_env (userenv.c:140)
    by func_userenv (userenv.c:218)
  Uninitialised value was created by a stack allocation
    at get_env (userenv.c:128)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: userenvtest.patch
Type: text/x-patch
Size: 643 bytes
Desc: not available
Url : http://www.winehq.org/pipermail/wine-devel/attachments/20080603/a7de4763/attachment.bin 


More information about the wine-devel mailing list