[PATCH 0/1] MR6349: widl: Remove unused variable.
From: Huw Davies <huw(a)codeweavers.com> --- tools/widl/write_sltg.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/tools/widl/write_sltg.c b/tools/widl/write_sltg.c index 5429b60c607..497cfb98d11 100644 --- a/tools/widl/write_sltg.c +++ b/tools/widl/write_sltg.c @@ -1155,7 +1155,7 @@ static int add_func_desc(struct sltg_typelib *typelib, struct sltg_data *data, v int idx, int dispid, short base_offset, struct sltg_hrefmap *hrefmap) { struct sltg_data ret_data, *arg_data; - int arg_count = 0, arg_data_size, optional = 0, defaults = 0, old_size; + int arg_count = 0, arg_data_size, optional = 0, old_size; int funcflags = 0, invokekind = 1 /* INVOKE_FUNC */, helpcontext; const char *helpstring; const var_t *arg; @@ -1218,9 +1218,7 @@ static int add_func_desc(struct sltg_typelib *typelib, struct sltg_data *data, v LIST_FOR_EACH_ENTRY(attr, arg->attrs, const attr_t, entry) { - if (attr->type == ATTR_DEFAULTVALUE) - defaults++; - else if(attr->type == ATTR_OPTIONAL) + if (attr->type == ATTR_OPTIONAL) optional++; } } -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/6349
This merge request was approved by Rémi Bernon. -- https://gitlab.winehq.org/wine/wine/-/merge_requests/6349
Looks good to me from a purely syntactic perspective, then i don't know if this was supposed to be doing something instead. -- https://gitlab.winehq.org/wine/wine/-/merge_requests/6349#note_79983
On Mon Aug 26 11:54:22 2024 +0000, Rémi Bernon wrote:
Looks good to me from a purely syntactic perspective, then i don't know if this was supposed to be doing something instead. Right, I meant to ask @dmitry to take a look.
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/6349#note_79989
On Mon Aug 26 11:54:22 2024 +0000, Huw Davies wrote:
Right, I meant to ask @dmitry to take a look. The whole SLTG thing was written using MSFT typelib code as a reference, and this chunk was copied from write_msft.c. Looks like I haven't found the meaning for it in SLTG typelibs.
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/6349#note_79990
participants (4)
-
Dmitry Timoshkov (@dmitry) -
Huw Davies -
Huw Davies (@huw) -
Rémi Bernon