Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
3dd9a78a
Commit
3dd9a78a
authored
May 27, 2022
by
Nikolay Sivov
Committed by
Alexandre Julliard
May 27, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d11: Always initialize out shader pointer in CreatePixelShader().
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
parent
6c818165
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
0 deletions
+14
-0
d3d10core.c
dlls/d3d10core/tests/d3d10core.c
+5
-0
device.c
dlls/d3d11/device.c
+4
-0
d3d11.c
dlls/d3d11/tests/d3d11.c
+5
-0
No files found.
dlls/d3d10core/tests/d3d10core.c
View file @
3dd9a78a
...
@@ -3906,6 +3906,11 @@ void main(point float4 vin[1] : POSITION, inout TriangleStream<gs_out> vout)
...
@@ -3906,6 +3906,11 @@ void main(point float4 vin[1] : POSITION, inout TriangleStream<gs_out> vout)
ok
(
!
vs
,
"Unexpected pointer %p.
\n
"
,
vs
);
ok
(
!
vs
,
"Unexpected pointer %p.
\n
"
,
vs
);
/* pixel shader */
/* pixel shader */
ps
=
(
void
*
)
0xdeadbeef
;
hr
=
ID3D10Device_CreatePixelShader
(
device
,
vs_2_0
,
sizeof
(
vs_2_0
),
&
ps
);
ok
(
hr
==
E_INVALIDARG
,
"Unexpected hr %#x.
\n
"
,
hr
);
ok
(
!
ps
,
"Unexpected pointer %p.
\n
"
,
ps
);
expected_refcount
=
get_refcount
(
device
)
+
1
;
expected_refcount
=
get_refcount
(
device
)
+
1
;
hr
=
ID3D10Device_CreatePixelShader
(
device
,
ps_4_0
,
sizeof
(
ps_4_0
),
&
ps
);
hr
=
ID3D10Device_CreatePixelShader
(
device
,
ps_4_0
,
sizeof
(
ps_4_0
),
&
ps
);
ok
(
SUCCEEDED
(
hr
),
"Failed to create SM4 pixel shader, hr %#x.
\n
"
,
hr
);
ok
(
SUCCEEDED
(
hr
),
"Failed to create SM4 pixel shader, hr %#x.
\n
"
,
hr
);
...
...
dlls/d3d11/device.c
View file @
3dd9a78a
...
@@ -3546,6 +3546,8 @@ static HRESULT STDMETHODCALLTYPE d3d11_device_CreatePixelShader(ID3D11Device2 *i
...
@@ -3546,6 +3546,8 @@ static HRESULT STDMETHODCALLTYPE d3d11_device_CreatePixelShader(ID3D11Device2 *i
TRACE
(
"iface %p, byte_code %p, byte_code_length %Iu, class_linkage %p, shader %p.
\n
"
,
TRACE
(
"iface %p, byte_code %p, byte_code_length %Iu, class_linkage %p, shader %p.
\n
"
,
iface
,
byte_code
,
byte_code_length
,
class_linkage
,
shader
);
iface
,
byte_code
,
byte_code_length
,
class_linkage
,
shader
);
*
shader
=
NULL
;
if
(
class_linkage
)
if
(
class_linkage
)
FIXME
(
"Class linkage is not implemented yet.
\n
"
);
FIXME
(
"Class linkage is not implemented yet.
\n
"
);
...
@@ -6284,6 +6286,8 @@ static HRESULT STDMETHODCALLTYPE d3d10_device_CreatePixelShader(ID3D10Device1 *i
...
@@ -6284,6 +6286,8 @@ static HRESULT STDMETHODCALLTYPE d3d10_device_CreatePixelShader(ID3D10Device1 *i
TRACE
(
"iface %p, byte_code %p, byte_code_length %Iu, shader %p.
\n
"
,
TRACE
(
"iface %p, byte_code %p, byte_code_length %Iu, shader %p.
\n
"
,
iface
,
byte_code
,
byte_code_length
,
shader
);
iface
,
byte_code
,
byte_code_length
,
shader
);
*
shader
=
NULL
;
if
(
FAILED
(
hr
=
d3d_pixel_shader_create
(
device
,
byte_code
,
byte_code_length
,
&
object
)))
if
(
FAILED
(
hr
=
d3d_pixel_shader_create
(
device
,
byte_code
,
byte_code_length
,
&
object
)))
return
hr
;
return
hr
;
...
...
dlls/d3d11/tests/d3d11.c
View file @
3dd9a78a
...
@@ -4848,6 +4848,11 @@ static void test_create_shader(const D3D_FEATURE_LEVEL feature_level)
...
@@ -4848,6 +4848,11 @@ static void test_create_shader(const D3D_FEATURE_LEVEL feature_level)
ok
(
hr
==
S_OK
,
"Feature level %#x: Got unexpected hr %#lx.
\n
"
,
feature_level
,
hr
);
ok
(
hr
==
S_OK
,
"Feature level %#x: Got unexpected hr %#lx.
\n
"
,
feature_level
,
hr
);
ID3D11PixelShader_Release
(
ps
);
ID3D11PixelShader_Release
(
ps
);
ps
=
(
void
*
)
0xdeadbeef
;
hr
=
ID3D11Device_CreatePixelShader
(
device
,
vs_2_0
,
sizeof
(
vs_2_0
),
NULL
,
&
ps
);
ok
(
hr
==
E_INVALIDARG
,
"Got unexpected hr %#lx.
\n
"
,
hr
);
ok
(
!
ps
,
"Unexpected pointer %p.
\n
"
,
ps
);
/* vertex shader */
/* vertex shader */
vs
=
(
void
*
)
0xdeadbeef
;
vs
=
(
void
*
)
0xdeadbeef
;
hr
=
ID3D11Device_CreateVertexShader
(
device
,
vs_2_0
,
sizeof
(
vs_2_0
),
NULL
,
&
vs
);
hr
=
ID3D11Device_CreateVertexShader
(
device
,
vs_2_0
,
sizeof
(
vs_2_0
),
NULL
,
&
vs
);
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment