Module: wine Branch: master Commit: 96be709c2e63d57ca83bbc755e3e8b83b8f92e7c URL: http://source.winehq.org/git/wine.git/?a=commit;h=96be709c2e63d57ca83bbc755e...
Author: Jacek Caban jacek@codeweavers.com Date: Fri Dec 28 01:59:51 2007 +0100
urlmon: RegisterNameSpace clean up.
---
dlls/urlmon/session.c | 6 +----- 1 files changed, 1 insertions(+), 5 deletions(-)
diff --git a/dlls/urlmon/session.c b/dlls/urlmon/session.c index 044b3ea..f5a644f 100644 --- a/dlls/urlmon/session.c +++ b/dlls/urlmon/session.c @@ -184,7 +184,6 @@ static HRESULT WINAPI InternetSession_RegisterNameSpace(IInternetSession *iface, const LPCWSTR *ppwzPatterns, DWORD dwReserved) { name_space *new_name_space; - int size;
TRACE("(%p %s %s %d %p %d)\n", pCF, debugstr_guid(rclsid), debugstr_w(pwzProtocol), cPatterns, ppwzPatterns, dwReserved); @@ -199,12 +198,9 @@ static HRESULT WINAPI InternetSession_RegisterNameSpace(IInternetSession *iface,
new_name_space = heap_alloc(sizeof(name_space));
- size = (strlenW(pwzProtocol)+1)*sizeof(WCHAR); - new_name_space->protocol = heap_alloc(size); - memcpy(new_name_space->protocol, pwzProtocol, size); - IClassFactory_AddRef(pCF); new_name_space->cf = pCF; + new_name_space->protocol = heap_strdupW(pwzProtocol); new_name_space->clsid = *rclsid;
new_name_space->next = name_space_list;