Marcus Meissner : netstat: Allocate WCHARs not CHARs (Coverity).
Module: wine Branch: master Commit: e7858100d6f5021e6409283f9e2157979693e285 URL: http://source.winehq.org/git/wine.git/?a=commit;h=e7858100d6f5021e6409283f9e... Author: Marcus Meissner <marcus(a)jet.franken.de> Date: Sun Sep 29 10:52:04 2013 +0200 netstat: Allocate WCHARs not CHARs (Coverity). --- programs/netstat/netstat.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/programs/netstat/netstat.c b/programs/netstat/netstat.c index fab39e3..0e52c36 100644 --- a/programs/netstat/netstat.c +++ b/programs/netstat/netstat.c @@ -90,7 +90,7 @@ static int __cdecl NETSTAT_wprintf(const WCHAR *format, ...) */ if (!output_bufW) output_bufW = HeapAlloc(GetProcessHeap(), 0, - MAX_WRITECONSOLE_SIZE); + MAX_WRITECONSOLE_SIZE*sizeof(WCHAR)); if (!output_bufW) { WINE_FIXME("Out of memory - could not allocate 2 x 64K buffers\n"); return 0;
participants (1)
-
Alexandre Julliard