Rob Shearman : kernel32: Fix the GetComputerName* functions to not write to the buffer at all if there is not enough space .

Alexandre Julliard julliard at wine.codeweavers.com
Fri Feb 16 07:08:41 CST 2007


Module: wine
Branch: master
Commit: fc5b795f7c544e1dff850174ebf69c8dba458549
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=fc5b795f7c544e1dff850174ebf69c8dba458549

Author: Rob Shearman <rob at codeweavers.com>
Date:   Thu Feb 15 23:22:18 2007 +0000

kernel32: Fix the GetComputerName* functions to not write to the buffer at all if there is not enough space.

Add tests for the GetComputerName* functions that show this issue.

Fix an off-by-one error in setting the size when there is not enough space.

Remove the exception handlers for GetComputerNameW,
GetComputerNameExA/W, since testing on XP SP2 shows that access
violations are not caught and these are not present on Win9x, which
does have an exception handler.

---

 dlls/kernel32/computername.c  |  100 +++++++++++--------------------
 dlls/kernel32/tests/environ.c |  131 +++++++++++++++++++++++++++++++++++++++++
 2 files changed, 166 insertions(+), 65 deletions(-)

Diff:   http://source.winehq.org/git/wine.git/?a=commitdiff;h=fc5b795f7c544e1dff850174ebf69c8dba458549



More information about the wine-cvs mailing list