Michael Stefaniuc : d3drm: Pass the correct pointer to IDirectXFileData_GetData (PVS-Studio).
Alexandre Julliard
julliard at wine.codeweavers.com
Thu Oct 30 09:23:15 CDT 2014
Module: wine
Branch: master
Commit: 0726542dedf481d3eb8c01825da038a71c5363c5
URL: http://source.winehq.org/git/wine.git/?a=commit;h=0726542dedf481d3eb8c01825da038a71c5363c5
Author: Michael Stefaniuc <mstefani at redhat.de>
Date: Thu Oct 30 11:24:20 2014 +0100
d3drm: Pass the correct pointer to IDirectXFileData_GetData (PVS-Studio).
Also remove an uneeded initialization of "size" as that is purely an
[OUT] parameter.
---
dlls/d3drm/d3drm.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/dlls/d3drm/d3drm.c b/dlls/d3drm/d3drm.c
index 06850bc..92ac272 100644
--- a/dlls/d3drm/d3drm.c
+++ b/dlls/d3drm/d3drm.c
@@ -1240,17 +1240,16 @@ static HRESULT load_data(IDirect3DRM3 *iface, IDirectXFileData *data_object, IID
/* Cannot be requested */
if (parent_frame)
{
- D3DRMMATRIX4D matrix;
+ D3DRMMATRIX4D *matrix;
DWORD size;
TRACE("Load Frame Transform Matrix data\n");
- size = sizeof(matrix);
- hr = IDirectXFileData_GetData(data_object, NULL, &size, (void**)matrix);
+ hr = IDirectXFileData_GetData(data_object, NULL, &size, (void**)&matrix);
if ((hr != DXFILE_OK) || (size != sizeof(matrix)))
goto end;
- hr = IDirect3DRMFrame3_AddTransform(parent_frame, D3DRMCOMBINE_REPLACE, matrix);
+ hr = IDirect3DRMFrame3_AddTransform(parent_frame, D3DRMCOMBINE_REPLACE, *matrix);
if (FAILED(hr))
goto end;
}
More information about the wine-cvs
mailing list