Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
67da604e
Commit
67da604e
authored
Mar 10, 2009
by
Henri Verbeet
Committed by
Alexandre Julliard
Mar 10, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Get rid of a few stack buffers.
parent
1fa83c95
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
7 deletions
+15
-7
baseshader.c
dlls/wined3d/baseshader.c
+14
-7
glsl_shader.c
dlls/wined3d/glsl_shader.c
+0
-0
wined3d_private.h
dlls/wined3d/wined3d_private.h
+1
-0
No files found.
dlls/wined3d/baseshader.c
View file @
67da604e
...
...
@@ -52,17 +52,12 @@ void shader_buffer_free(struct SHADER_BUFFER *buffer)
HeapFree
(
GetProcessHeap
(),
0
,
buffer
->
buffer
);
}
int
shader_addline
(
SHADER_BUFFER
*
buffer
,
const
char
*
format
,
...)
{
int
shader_vaddline
(
SHADER_BUFFER
*
buffer
,
const
char
*
format
,
va_list
args
)
{
char
*
base
=
buffer
->
buffer
+
buffer
->
bsize
;
int
rc
;
va_list
args
;
va_start
(
args
,
format
);
rc
=
vsnprintf
(
base
,
SHADER_PGMSIZE
-
1
-
buffer
->
bsize
,
format
,
args
);
va_end
(
args
);
if
(
rc
<
0
||
/* C89 */
rc
>
SHADER_PGMSIZE
-
1
-
buffer
->
bsize
)
{
/* C99 */
...
...
@@ -88,6 +83,18 @@ int shader_addline(
return
0
;
}
int
shader_addline
(
SHADER_BUFFER
*
buffer
,
const
char
*
format
,
...)
{
int
ret
;
va_list
args
;
va_start
(
args
,
format
);
ret
=
shader_vaddline
(
buffer
,
format
,
args
);
va_end
(
args
);
return
ret
;
}
void
shader_init
(
struct
IWineD3DBaseShaderClass
*
shader
,
IWineD3DDevice
*
device
,
const
SHADER_OPCODE
*
instruction_table
)
{
...
...
dlls/wined3d/glsl_shader.c
View file @
67da604e
This diff is collapsed.
Click to expand it.
dlls/wined3d/wined3d_private.h
View file @
67da604e
...
...
@@ -2219,6 +2219,7 @@ typedef struct SHADER_PARSE_STATE {
extern
int
shader_addline
(
SHADER_BUFFER
*
buffer
,
const
char
*
fmt
,
...)
PRINTF_ATTR
(
2
,
3
);
int
shader_vaddline
(
SHADER_BUFFER
*
buffer
,
const
char
*
fmt
,
va_list
args
);
const
SHADER_OPCODE
*
shader_get_opcode
(
const
SHADER_OPCODE
*
shader_ins
,
DWORD
shader_version
,
DWORD
code
);
...
...
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