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
95515243
Commit
95515243
authored
Oct 22, 2010
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
widl: Output a format string table and server info structure for stubs.
parent
4c41dd5f
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
33 additions
and
4 deletions
+33
-4
proxy.c
tools/widl/proxy.c
+32
-4
widltypes.h
tools/widl/widltypes.h
+1
-0
No files found.
tools/widl/proxy.c
View file @
95515243
...
...
@@ -579,7 +579,7 @@ static void write_proxy(type_t *iface, unsigned int *proc_offset)
/* FIXME: check for [oleautomation], shouldn't generate proxies/stubs if specified */
STATEMENTS_FOR_EACH_FUNC
(
stmt
,
type_iface_get_stmts
(
iface
))
{
const
var_t
*
func
=
stmt
->
u
.
var
;
var_t
*
func
=
stmt
->
u
.
var
;
if
(
first_func
)
{
fprintf
(
proxy
,
"/*****************************************************************************
\n
"
);
fprintf
(
proxy
,
" * %s interface
\n
"
,
iface
->
name
);
...
...
@@ -601,6 +601,7 @@ static void write_proxy(type_t *iface, unsigned int *proc_offset)
}
}
}
func
->
procstring_offset
=
*
proc_offset
;
gen_proxy
(
iface
,
func
,
idx
,
*
proc_offset
);
gen_stub
(
iface
,
func
,
cname
,
*
proc_offset
);
*
proc_offset
+=
get_size_procformatstring_func
(
func
);
...
...
@@ -609,6 +610,19 @@ static void write_proxy(type_t *iface, unsigned int *proc_offset)
count
=
count_methods
(
iface
);
/* proc format string offsets */
print_proxy
(
"static const unsigned short %s_FormatStringOffsetTable[] =
\n
"
,
iface
->
name
);
print_proxy
(
"{
\n
"
);
indent
++
;
STATEMENTS_FOR_EACH_FUNC
(
stmt
,
type_iface_get_stmts
(
iface
))
{
var_t
*
func
=
stmt
->
u
.
var
;
if
(
is_local
(
func
->
attrs
))
continue
;
print_proxy
(
"%u, /* %s */
\n
"
,
func
->
procstring_offset
,
func
->
name
);
}
indent
--
;
print_proxy
(
"};
\n\n
"
);
/* proxy vtable */
print_proxy
(
"static %sCINTERFACE_PROXY_VTABLE(%d) _%sProxyVtbl =
\n
"
,
need_delegation_indirect
(
iface
)
?
""
:
"const "
,
count
,
iface
->
name
);
...
...
@@ -626,8 +640,22 @@ static void write_proxy(type_t *iface, unsigned int *proc_offset)
indent
--
;
print_proxy
(
"}
\n
"
);
indent
--
;
print_proxy
(
"};
\n
"
);
fprintf
(
proxy
,
"
\n\n
"
);
print_proxy
(
"};
\n\n
"
);
/* server info */
print_proxy
(
"static const MIDL_SERVER_INFO %s_ServerInfo =
\n
"
,
iface
->
name
);
print_proxy
(
"{
\n
"
);
indent
++
;
print_proxy
(
"&Object_StubDesc,
\n
"
);
print_proxy
(
"0,
\n
"
);
print_proxy
(
"__MIDL_ProcFormatString.Format,
\n
"
);
print_proxy
(
"&%s_FormatStringOffsetTable[-3],
\n
"
,
iface
->
name
);
print_proxy
(
"0,
\n
"
);
print_proxy
(
"0,
\n
"
);
print_proxy
(
"0,
\n
"
);
print_proxy
(
"0
\n
"
);
indent
--
;
print_proxy
(
"};
\n\n
"
);
/* stub vtable */
print_proxy
(
"static const PRPC_STUB_FUNCTION %s_table[] =
\n
"
,
iface
->
name
);
...
...
@@ -645,7 +673,7 @@ static void write_proxy(type_t *iface, unsigned int *proc_offset)
print_proxy
(
"{
\n
"
);
indent
++
;
print_proxy
(
"&IID_%s,
\n
"
,
iface
->
name
);
print_proxy
(
"
0,
\n
"
);
print_proxy
(
"
&%s_ServerInfo,
\n
"
,
iface
->
name
);
print_proxy
(
"%d,
\n
"
,
count
);
print_proxy
(
"&%s_table[-3],
\n
"
,
iface
->
name
);
indent
--
;
...
...
tools/widl/widltypes.h
View file @
95515243
...
...
@@ -420,6 +420,7 @@ struct _var_t {
attr_list_t
*
attrs
;
expr_t
*
eval
;
enum
storage_class
stgclass
;
unsigned
int
procstring_offset
;
struct
_loc_info_t
loc_info
;
...
...
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