From 39b702d16eb594f7754189ed4e0359da5fc7a1c7 Mon Sep 17 00:00:00 2001 From: Johannes Anderwald Date: Tue, 22 Sep 2009 20:09:11 +0000 Subject: [PATCH] - Fix memory leak - Fix displaying of random characters if there is no device name svn path=/trunk/; revision=43116 --- reactos/dll/win32/netshell/shfldr_netconnect.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/reactos/dll/win32/netshell/shfldr_netconnect.c b/reactos/dll/win32/netshell/shfldr_netconnect.c index 4c602270384..273c3edc62e 100644 --- a/reactos/dll/win32/netshell/shfldr_netconnect.c +++ b/reactos/dll/win32/netshell/shfldr_netconnect.c @@ -644,6 +644,11 @@ static HRESULT WINAPI ISF_NetConnect_fnGetDetailsOf (IShellFolder2 * iface, psd->str.uType = STRRET_WSTR; hr = SHStrDupW(buffer, &psd->str.u.pOleStr); } + else + { + psd->str.u.cStr[0] = '\0'; + psd->str.uType = STRRET_CSTR; + } break; case COLUMN_PHONE: case COLUMN_OWNER: @@ -651,9 +656,8 @@ static HRESULT WINAPI ISF_NetConnect_fnGetDetailsOf (IShellFolder2 * iface, psd->str.uType = STRRET_CSTR; break; } -#if 0 + NcFreeNetconProperties(pProperties); -#endif return hr; }