oledlg: Assign to structs instead of using memcpy.

This commit is contained in:
Andrew Talbot 2008-03-13 20:52:16 +00:00 committed by Alexandre Julliard
parent 612e4c2b17
commit 1b2dc823d2
1 changed files with 2 additions and 2 deletions

View File

@ -377,7 +377,7 @@ static BOOL UIINSERTOBJECTDLG_PopulateObjectTypes(InsertObjectDlgInfo* pdlgInfo)
if (ERROR_SUCCESS == RegQueryValueW(hkey, NULL, keydesc, &len))
{
CLSID* lpclsid = HeapAlloc(GetProcessHeap(), 0, sizeof(CLSID));
memcpy(lpclsid, &clsid, sizeof(CLSID));
*lpclsid = clsid;
len = SendMessageW(pdlgInfo->hwndObjTypeLB, LB_ADDSTRING, 0, (LPARAM)keydesc);
SendMessageW(pdlgInfo->hwndObjTypeLB, LB_SETITEMDATA, (WPARAM)len, (LPARAM)lpclsid);
@ -453,7 +453,7 @@ static BOOL UIINSERTOBJECTDLG_OnOpen(InsertObjectDlgInfo* pdlgInfo)
{
CLSID* clsid = (CLSID*) SendMessageA(pdlgInfo->hwndObjTypeLB,
LB_GETITEMDATA, (WPARAM)index, 0);
memcpy(&pdlgInfo->lpOleUIInsertObject->clsid, clsid, sizeof(CLSID));
pdlgInfo->lpOleUIInsertObject->clsid = *clsid;
if (pdlgInfo->lpOleUIInsertObject->dwFlags & IOF_CREATENEWOBJECT)
{