Alexandre Julliard : widl: Use get_size_procformatstring_func() for clients too instead of duplicating the code.

Alexandre Julliard julliard at winehq.org
Fri Oct 22 12:30:42 CDT 2010


Module: wine
Branch: master
Commit: 226e96342925b6c17d61f0ed16c1ec95a9700d96
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=226e96342925b6c17d61f0ed16c1ec95a9700d96

Author: Alexandre Julliard <julliard at winehq.org>
Date:   Thu Oct 21 21:35:21 2010 +0200

widl: Use get_size_procformatstring_func() for clients too instead of duplicating the code.

---

 tools/widl/client.c |   11 +----------
 1 files changed, 1 insertions(+), 10 deletions(-)

diff --git a/tools/widl/client.c b/tools/widl/client.c
index 569a18b..693227f 100644
--- a/tools/widl/client.c
+++ b/tools/widl/client.c
@@ -76,7 +76,6 @@ static void write_function_stubs(type_t *iface, unsigned int *proc_offset)
 {
     const statement_t *stmt;
     const char *implicit_handle = get_attrp(iface->attrs, ATTR_IMPLICIT_HANDLE);
-    const var_t *var;
     int method_count = 0;
 
     if (!implicit_handle)
@@ -297,15 +296,7 @@ static void write_function_stubs(type_t *iface, unsigned int *proc_offset)
         }
 
         /* update proc_offset */
-        if (args)
-        {
-            LIST_FOR_EACH_ENTRY( var, args, const var_t, entry )
-                *proc_offset += get_size_procformatstring_type(var->name, var->type, var->attrs);
-        }
-        if (!is_void(type_function_get_rettype(func->type)))
-            *proc_offset += get_size_procformatstring_type("return value", type_function_get_rettype(func->type), NULL);
-        else
-            *proc_offset += 2; /* FC_END and FC_PAD */
+        *proc_offset += get_size_procformatstring_func( func );
 
         indent--;
         print_client("}\n");




More information about the wine-cvs mailing list