mirror of
https://github.com/reactos/reactos.git
synced 2025-05-24 19:56:38 +00:00
fixing smaller bugs
svn path=/trunk/; revision=26737
This commit is contained in:
parent
bf51ef9a82
commit
e535eb641e
2 changed files with 17 additions and 5 deletions
|
@ -130,11 +130,14 @@ HRESULT WINAPI Main_DirectDraw_CreateSurface (LPDIRECTDRAW7 iface, LPDDSURFACEDE
|
|||
|
||||
DX_WINDBG_trace();
|
||||
|
||||
if (pUnkOuter)
|
||||
return DDERR_GENERIC;
|
||||
|
||||
/* FIXME vaildate input pointers or warp everthing with SEH */
|
||||
|
||||
if (pUnkOuter)
|
||||
{
|
||||
/* FIXME send back right return code */
|
||||
return DDERR_GENERIC;
|
||||
}
|
||||
|
||||
EnterCriticalSection(&ddcs);
|
||||
|
||||
ret = DDERR_GENERIC;
|
||||
|
@ -164,13 +167,21 @@ HRESULT WINAPI Main_DirectDraw_CreateSurface (LPDIRECTDRAW7 iface, LPDDSURFACEDE
|
|||
return DDERR_INVALIDPARAMS;
|
||||
}
|
||||
|
||||
/* FIXME add one gbl check with one pDDSD check */
|
||||
ret = Internal_CreateSurface(dd_int,ppSurf,&dd_desc_v2);
|
||||
/* check if this process belong to this ddraw */
|
||||
if ( dd_int->lcl->dwProcessId != GetCurrentProcessId() )
|
||||
{
|
||||
/* FIXME send back right return code */
|
||||
return DDERR_GENERIC;
|
||||
}
|
||||
|
||||
ret = internal_CreateSurface(dd_int,dd_desc_v2,ppSurf,pUnkOuter);
|
||||
|
||||
LeaveCriticalSection(&ddcs);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
|
||||
IDirectDraw7Vtbl DirectDraw7_Vtable =
|
||||
{
|
||||
Main_DirectDraw_QueryInterface,
|
||||
|
|
|
@ -21,6 +21,7 @@ void CopyDDSurfDescToDDSurfDesc2(LPDDSURFACEDESC2 dst_pDesc, LPDDSURFACEDESC src
|
|||
{
|
||||
RtlZeroMemory(dst_pDesc,sizeof(DDSURFACEDESC2));
|
||||
RtlCopyMemory(dst_pDesc,src_pDesc,sizeof(DDSURFACEDESC));
|
||||
dst_pDesc->dwSize = sizeof(DDSURFACEDESC2);
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue