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
4102d8a0
Commit
4102d8a0
authored
May 30, 2013
by
Christian Costa
Committed by
Alexandre Julliard
Jun 03, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3dxof: Fix list of float and integer in binary mode.
parent
7325b798
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
21 additions
and
14 deletions
+21
-14
d3dxof_private.h
dlls/d3dxof/d3dxof_private.h
+1
-0
parsing.c
dlls/d3dxof/parsing.c
+18
-12
d3dxof.c
dlls/d3dxof/tests/d3dxof.c
+2
-2
No files found.
dlls/d3dxof/d3dxof_private.h
View file @
4102d8a0
...
...
@@ -127,6 +127,7 @@ typedef struct {
BOOL
txt
;
DWORD
list_nb_elements
;
BOOL
list_type_float
;
BOOL
list_separator
;
ULONG
cur_pos_data
;
LPBYTE
cur_pstrings
;
BYTE
value
[
100
];
...
...
dlls/d3dxof/parsing.c
View file @
4102d8a0
...
...
@@ -743,16 +743,26 @@ static WORD parse_TOKEN(parse_buffer * buf)
if
(
buf
->
list_nb_elements
)
{
token
=
buf
->
list_type_float
?
TOKEN_FLOAT
:
TOKEN_INTEGER
;
buf
->
list_nb_elements
--
;
{
DWORD
integer
;
if
(
buf
->
list_separator
)
{
buf
->
list_nb_elements
--
;
buf
->
list_separator
=
FALSE
;
/* Insert separarator between each values and since list does not accept separator at the end
use a comma so any extra separator will generate an error */
token
=
TOKEN_COMMA
;
}
else
{
DWORD
value
;
if
(
!
read_bytes
(
buf
,
&
integer
,
4
))
return
TOKEN_ERROR
;
if
(
!
read_bytes
(
buf
,
&
value
,
4
))
return
TOKEN_ERROR
;
*
(
DWORD
*
)
buf
->
value
=
value
;
*
(
DWORD
*
)
buf
->
value
=
integer
;
}
buf
->
list_separator
=
TRUE
;
/* Convert list into a serie of their basic type counterpart */
token
=
buf
->
list_type_float
?
TOKEN_FLOAT
:
TOKEN_INTEGER
;
}
dump_TOKEN
(
token
);
return
token
;
}
...
...
@@ -1288,10 +1298,6 @@ static BOOL parse_object_parts(parse_buffer * buf, BOOL allow_optional)
{
buf
->
pxo
->
size
=
buf
->
cur_pos_data
-
buf
->
pxo
->
pos_data
;
/* Skip trailing semicolon */
while
(
check_TOKEN
(
buf
)
==
TOKEN_SEMICOLON
)
get_TOKEN
(
buf
);
while
(
1
)
{
if
(
check_TOKEN
(
buf
)
==
TOKEN_OBRACE
)
...
...
dlls/d3dxof/tests/d3dxof.c
View file @
4102d8a0
...
...
@@ -921,11 +921,11 @@ static void test_syntax_semicolon_comma(void)
/* Test object with a single integer list in binary mode */
ret
=
test_buffer_object
(
dxfile
,
object_syntax_full_integer_list_bin
,
sizeof
(
object_syntax_full_integer_list_bin
));
todo_wine
ok
(
ret
==
DXFILE_OK
,
"test_buffer_object failed with %#x
\n
"
,
ret
);
ok
(
ret
==
DXFILE_OK
,
"test_buffer_object failed with %#x
\n
"
,
ret
);
/* Test object with mixed integer list and integers + single comma separators in binary mode */
ret
=
test_buffer_object
(
dxfile
,
object_syntax_mixed_integer_list_bin
,
sizeof
(
object_syntax_mixed_integer_list_bin
));
todo_wine
ok
(
ret
==
DXFILE_OK
,
"test_buffer_object failed with %#x
\n
"
,
ret
);
ok
(
ret
==
DXFILE_OK
,
"test_buffer_object failed with %#x
\n
"
,
ret
);
/* Test integer list followed by a semicolon in binary mode */
ret
=
test_buffer_object
(
dxfile
,
object_syntax_integer_list_semicolon_bin
,
sizeof
(
object_syntax_integer_list_semicolon_bin
));
...
...
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