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
14c38955
Commit
14c38955
authored
Feb 07, 2013
by
Michael Stefaniuc
Committed by
Alexandre Julliard
Feb 07, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d8: Remove ERR() on HeapAlloc failure for small sizes known at compile time.
parent
1eff4669
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
0 additions
and
34 deletions
+0
-34
d3d8_main.c
dlls/d3d8/d3d8_main.c
+0
-3
device.c
dlls/d3d8/device.c
+0
-22
directx.c
dlls/d3d8/directx.c
+0
-3
shader.c
dlls/d3d8/shader.c
+0
-3
swapchain.c
dlls/d3d8/swapchain.c
+0
-3
No files found.
dlls/d3d8/d3d8_main.c
View file @
14c38955
...
...
@@ -42,10 +42,7 @@ IDirect3D8 * WINAPI DECLSPEC_HOTPATCH Direct3DCreate8(UINT sdk_version)
TRACE
(
"sdk_version %#x.
\n
"
,
sdk_version
);
if
(
!
(
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
object
))))
{
ERR
(
"Failed to allocate d3d8 object memory.
\n
"
);
return
NULL
;
}
if
(
!
d3d8_init
(
object
))
{
...
...
dlls/d3d8/device.c
View file @
14c38955
...
...
@@ -723,10 +723,7 @@ static HRESULT WINAPI d3d8_device_CreateTexture(IDirect3DDevice8 *iface,
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
object
));
if
(
!
object
)
{
ERR
(
"Failed to allocate texture memory.
\n
"
);
return
D3DERR_OUTOFVIDEOMEMORY
;
}
hr
=
texture_init
(
object
,
device
,
width
,
height
,
levels
,
usage
,
format
,
pool
);
if
(
FAILED
(
hr
))
...
...
@@ -755,10 +752,7 @@ static HRESULT WINAPI d3d8_device_CreateVolumeTexture(IDirect3DDevice8 *iface,
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
object
));
if
(
!
object
)
{
ERR
(
"Failed to allocate volume texture memory.
\n
"
);
return
D3DERR_OUTOFVIDEOMEMORY
;
}
hr
=
volumetexture_init
(
object
,
device
,
width
,
height
,
depth
,
levels
,
usage
,
format
,
pool
);
if
(
FAILED
(
hr
))
...
...
@@ -786,10 +780,7 @@ static HRESULT WINAPI d3d8_device_CreateCubeTexture(IDirect3DDevice8 *iface, UIN
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
object
));
if
(
!
object
)
{
ERR
(
"Failed to allocate cube texture memory.
\n
"
);
return
D3DERR_OUTOFVIDEOMEMORY
;
}
hr
=
cubetexture_init
(
object
,
device
,
edge_length
,
levels
,
usage
,
format
,
pool
);
if
(
FAILED
(
hr
))
...
...
@@ -817,10 +808,7 @@ static HRESULT WINAPI d3d8_device_CreateVertexBuffer(IDirect3DDevice8 *iface, UI
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
object
));
if
(
!
object
)
{
ERR
(
"Failed to allocate buffer memory.
\n
"
);
return
D3DERR_OUTOFVIDEOMEMORY
;
}
hr
=
vertexbuffer_init
(
object
,
device
,
size
,
usage
,
fvf
,
pool
);
if
(
FAILED
(
hr
))
...
...
@@ -848,10 +836,7 @@ static HRESULT WINAPI d3d8_device_CreateIndexBuffer(IDirect3DDevice8 *iface, UIN
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
object
));
if
(
!
object
)
{
ERR
(
"Failed to allocate buffer memory.
\n
"
);
return
D3DERR_OUTOFVIDEOMEMORY
;
}
hr
=
indexbuffer_init
(
object
,
device
,
size
,
usage
,
format
,
pool
);
if
(
FAILED
(
hr
))
...
...
@@ -2150,7 +2135,6 @@ static HRESULT WINAPI d3d8_device_CreateVertexShader(IDirect3DDevice8 *iface,
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
object
));
if
(
!
object
)
{
ERR
(
"Failed to allocate vertex shader memory.
\n
"
);
*
shader
=
0
;
return
E_OUTOFMEMORY
;
}
...
...
@@ -2216,10 +2200,7 @@ static struct d3d8_vertex_declaration *d3d8_device_get_fvf_declaration(struct d3
TRACE
(
"not found. Creating and inserting at position %d.
\n
"
,
low
);
if
(
!
(
d3d8_declaration
=
HeapAlloc
(
GetProcessHeap
(),
0
,
sizeof
(
*
d3d8_declaration
))))
{
ERR
(
"Memory allocation failed.
\n
"
);
return
NULL
;
}
if
(
FAILED
(
hr
=
d3d8_vertex_declaration_init_fvf
(
d3d8_declaration
,
device
,
fvf
)))
{
...
...
@@ -2532,10 +2513,7 @@ static HRESULT WINAPI d3d8_device_CreatePixelShader(IDirect3DDevice8 *iface,
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
object
));
if
(
!
object
)
{
ERR
(
"Failed to allocate pixel shader memmory.
\n
"
);
return
E_OUTOFMEMORY
;
}
wined3d_mutex_lock
();
handle
=
d3d8_allocate_handle
(
&
device
->
handle_table
,
object
,
D3D8_HANDLE_PS
);
...
...
dlls/d3d8/directx.c
View file @
14c38955
...
...
@@ -364,10 +364,7 @@ static HRESULT WINAPI d3d8_CreateDevice(IDirect3D8 *iface, UINT adapter,
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
object
));
if
(
!
object
)
{
ERR
(
"Failed to allocate device memory.
\n
"
);
return
E_OUTOFMEMORY
;
}
hr
=
device_init
(
object
,
d3d8
,
d3d8
->
wined3d
,
adapter
,
device_type
,
focus_window
,
flags
,
parameters
);
if
(
FAILED
(
hr
))
...
...
dlls/d3d8/shader.c
View file @
14c38955
...
...
@@ -61,10 +61,7 @@ static HRESULT d3d8_vertexshader_create_vertexdeclaration(struct d3d8_device *de
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
object
));
if
(
!
object
)
{
ERR
(
"Memory allocation failed.
\n
"
);
return
E_OUTOFMEMORY
;
}
hr
=
d3d8_vertex_declaration_init
(
object
,
device
,
declaration
,
shader_handle
);
if
(
FAILED
(
hr
))
...
...
dlls/d3d8/swapchain.c
View file @
14c38955
...
...
@@ -183,10 +183,7 @@ HRESULT d3d8_swapchain_create(struct d3d8_device *device, struct wined3d_swapcha
HRESULT
hr
;
if
(
!
(
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
object
))))
{
ERR
(
"Failed to allocate swapchain memory.
\n
"
);
return
E_OUTOFMEMORY
;
}
if
(
FAILED
(
hr
=
swapchain_init
(
object
,
device
,
desc
)))
{
...
...
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