mirror of
https://github.com/reactos/reactos.git
synced 2025-05-25 04:03:56 +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();
|
DX_WINDBG_trace();
|
||||||
|
|
||||||
if (pUnkOuter)
|
|
||||||
return DDERR_GENERIC;
|
|
||||||
|
|
||||||
/* FIXME vaildate input pointers or warp everthing with SEH */
|
/* FIXME vaildate input pointers or warp everthing with SEH */
|
||||||
|
|
||||||
|
if (pUnkOuter)
|
||||||
|
{
|
||||||
|
/* FIXME send back right return code */
|
||||||
|
return DDERR_GENERIC;
|
||||||
|
}
|
||||||
|
|
||||||
EnterCriticalSection(&ddcs);
|
EnterCriticalSection(&ddcs);
|
||||||
|
|
||||||
ret = DDERR_GENERIC;
|
ret = DDERR_GENERIC;
|
||||||
|
@ -164,13 +167,21 @@ HRESULT WINAPI Main_DirectDraw_CreateSurface (LPDIRECTDRAW7 iface, LPDDSURFACEDE
|
||||||
return DDERR_INVALIDPARAMS;
|
return DDERR_INVALIDPARAMS;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* FIXME add one gbl check with one pDDSD check */
|
/* check if this process belong to this ddraw */
|
||||||
ret = Internal_CreateSurface(dd_int,ppSurf,&dd_desc_v2);
|
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);
|
LeaveCriticalSection(&ddcs);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
IDirectDraw7Vtbl DirectDraw7_Vtable =
|
IDirectDraw7Vtbl DirectDraw7_Vtable =
|
||||||
{
|
{
|
||||||
Main_DirectDraw_QueryInterface,
|
Main_DirectDraw_QueryInterface,
|
||||||
|
|
|
@ -21,6 +21,7 @@ void CopyDDSurfDescToDDSurfDesc2(LPDDSURFACEDESC2 dst_pDesc, LPDDSURFACEDESC src
|
||||||
{
|
{
|
||||||
RtlZeroMemory(dst_pDesc,sizeof(DDSURFACEDESC2));
|
RtlZeroMemory(dst_pDesc,sizeof(DDSURFACEDESC2));
|
||||||
RtlCopyMemory(dst_pDesc,src_pDesc,sizeof(DDSURFACEDESC));
|
RtlCopyMemory(dst_pDesc,src_pDesc,sizeof(DDSURFACEDESC));
|
||||||
|
dst_pDesc->dwSize = sizeof(DDSURFACEDESC2);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue