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
4f4763ab
Commit
4f4763ab
authored
Aug 21, 2019
by
Zebediah Figura
Committed by
Alexandre Julliard
Aug 21, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
widl: Handle encapsulated unions in type libraries.
Signed-off-by:
Zebediah Figura
<
z.figura12@gmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
732f67ed
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
2 deletions
+12
-2
write_msft.c
tools/widl/write_msft.c
+12
-2
No files found.
tools/widl/write_msft.c
View file @
4f4763ab
...
...
@@ -976,6 +976,7 @@ static int encode_type(
switch
(
type_get_type
(
type
))
{
case
TYPE_STRUCT
:
case
TYPE_ENCAPSULATED_UNION
:
add_structure_typeinfo
(
typelib
,
type
);
break
;
case
TYPE_INTERFACE
:
...
...
@@ -2119,6 +2120,7 @@ static void add_interface_typeinfo(msft_typelib_t *typelib, type_t *interface)
static
void
add_structure_typeinfo
(
msft_typelib_t
*
typelib
,
type_t
*
structure
)
{
var_list_t
*
fields
;
int
idx
=
0
;
var_t
*
cur
;
msft_typeinfo_t
*
msft_typeinfo
;
...
...
@@ -2130,9 +2132,16 @@ static void add_structure_typeinfo(msft_typelib_t *typelib, type_t *structure)
msft_typeinfo
=
create_msft_typeinfo
(
typelib
,
TKIND_RECORD
,
structure
->
name
,
structure
->
attrs
);
msft_typeinfo
->
typeinfo
->
size
=
0
;
if
(
type_struct_get_fields
(
structure
))
LIST_FOR_EACH_ENTRY
(
cur
,
type_struct_get_fields
(
structure
),
var_t
,
entry
)
if
(
type_get_type
(
structure
)
==
TYPE_STRUCT
)
fields
=
type_struct_get_fields
(
structure
);
else
fields
=
type_encapsulated_union_get_fields
(
structure
);
if
(
fields
)
{
LIST_FOR_EACH_ENTRY
(
cur
,
fields
,
var_t
,
entry
)
add_var_desc
(
msft_typeinfo
,
idx
++
,
cur
);
}
}
static
void
add_enum_typeinfo
(
msft_typelib_t
*
typelib
,
type_t
*
enumeration
)
...
...
@@ -2320,6 +2329,7 @@ static void add_type_typeinfo(msft_typelib_t *typelib, type_t *type)
add_interface_typeinfo
(
typelib
,
type
);
break
;
case
TYPE_STRUCT
:
case
TYPE_ENCAPSULATED_UNION
:
add_structure_typeinfo
(
typelib
,
type
);
break
;
case
TYPE_ENUM
:
...
...
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