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
af058da8
Commit
af058da8
authored
Apr 03, 2024
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
widl: Use padding instead of alignment in structure format strings.
For compatibility with midl.
parent
855eb3af
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
17 deletions
+4
-17
typegen.c
tools/widl/typegen.c
+4
-17
No files found.
tools/widl/typegen.c
View file @
af058da8
...
@@ -3161,25 +3161,12 @@ static void write_struct_members(FILE *file, const type_t *type,
...
@@ -3161,25 +3161,12 @@ static void write_struct_members(FILE *file, const type_t *type,
if
(
!
is_conformant_array
(
ft
)
||
type_array_is_decl_as_ptr
(
ft
))
if
(
!
is_conformant_array
(
ft
)
||
type_array_is_decl_as_ptr
(
ft
))
{
{
if
((
align
-
1
)
&
offset
)
unsigned
short
aligned
=
ROUND_SIZE
(
offset
,
align
);
if
(
aligned
>
offset
)
{
{
unsigned
char
fc
=
0
;
unsigned
char
fc
=
FC_STRUCTPAD1
+
(
aligned
-
offset
)
-
1
;
switch
(
align
)
{
case
2
:
fc
=
FC_ALIGNM2
;
break
;
case
4
:
fc
=
FC_ALIGNM4
;
break
;
case
8
:
fc
=
FC_ALIGNM8
;
break
;
default:
error
(
"write_struct_members: cannot align type %d
\n
"
,
type_get_type
(
ft
));
}
print_file
(
file
,
2
,
"0x%x,
\t
/* %s */
\n
"
,
fc
,
string_of_type
(
fc
));
print_file
(
file
,
2
,
"0x%x,
\t
/* %s */
\n
"
,
fc
,
string_of_type
(
fc
));
offset
=
ROUND_SIZE
(
offset
,
align
)
;
offset
=
aligned
;
*
typestring_offset
+=
1
;
*
typestring_offset
+=
1
;
}
}
write_member_type
(
file
,
type
,
is_complex
,
field
->
attrs
,
field
->
declspec
.
type
,
corroff
,
write_member_type
(
file
,
type
,
is_complex
,
field
->
attrs
,
field
->
declspec
.
type
,
corroff
,
...
...
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