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
f2fe2f7e
Commit
f2fe2f7e
authored
Mar 23, 2010
by
Christian Costa
Committed by
Alexandre Julliard
Mar 23, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3dxof: Increase MAX_SUBOBJECTS and do the corresponding checks at the right place.
parent
61cb53e2
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
8 deletions
+15
-8
d3dxof.c
dlls/d3dxof/d3dxof.c
+0
-7
d3dxof_private.h
dlls/d3dxof/d3dxof_private.h
+1
-1
parsing.c
dlls/d3dxof/parsing.c
+14
-0
No files found.
dlls/d3dxof/d3dxof.c
View file @
f2fe2f7e
...
...
@@ -1104,13 +1104,6 @@ static HRESULT WINAPI IDirectXFileEnumObjectImpl_GetNextDataObject(IDirectXFileE
goto
error
;
}
if
(
This
->
buf
.
pxo
->
nb_subobjects
>
MAX_SUBOBJECTS
)
{
FIXME
(
"Too many subobjects %d
\n
"
,
This
->
buf
.
pxo
->
nb_subobjects
);
hr
=
DXFILEERR_BADALLOC
;
goto
error
;
}
object
->
pstrings
=
pstrings
;
object
->
pobj
=
This
->
buf
.
pxo
;
object
->
cur_enum_object
=
0
;
...
...
dlls/d3dxof/d3dxof_private.h
View file @
f2fe2f7e
...
...
@@ -39,7 +39,7 @@
#define MAX_CHILDS 100
#define MAX_TEMPLATES 200
#define MAX_OBJECTS 500
#define MAX_SUBOBJECTS
5
00
#define MAX_SUBOBJECTS
20
00
#define MAX_STRINGS_BUFFER 10000
typedef
struct
{
...
...
dlls/d3dxof/parsing.c
View file @
f2fe2f7e
...
...
@@ -1212,6 +1212,13 @@ _exit:
ERR
(
"Reference to unknown object %s
\n
"
,
(
char
*
)
buf
->
value
);
return
FALSE
;
}
if
(
buf
->
pxo
->
root
->
nb_subobjects
>=
MAX_SUBOBJECTS
)
{
FIXME
(
"Too many sub-objects
\n
"
);
return
FALSE
;
}
buf
->
pxo
->
childs
[
buf
->
pxo
->
nb_childs
]
=
&
buf
->
pxo_tab
[
buf
->
pxo
->
root
->
nb_subobjects
++
];
buf
->
pxo
->
childs
[
buf
->
pxo
->
nb_childs
]
->
ptarget
=
&
(
buf
->
pxo_globals
[
i
])[
j
];
buf
->
pxo
->
nb_childs
++
;
...
...
@@ -1219,6 +1226,13 @@ _exit:
else
if
(
check_TOKEN
(
buf
)
==
TOKEN_NAME
)
{
xobject
*
pxo
=
buf
->
pxo
;
if
(
buf
->
pxo
->
root
->
nb_subobjects
>=
MAX_SUBOBJECTS
)
{
FIXME
(
"Too many sub-objects
\n
"
);
return
FALSE
;
}
buf
->
pxo
=
buf
->
pxo
->
childs
[
buf
->
pxo
->
nb_childs
]
=
&
buf
->
pxo_tab
[
buf
->
pxo
->
root
->
nb_subobjects
++
];
TRACE
(
"Enter optional %s
\n
"
,
(
char
*
)
buf
->
value
);
...
...
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