[PATCH] vbscript: fix return value of lookup_identifier().

Robert Wilhelm robert.wilhelm at gmx.net
Tue Sep 29 11:44:57 CDT 2020


Signed-off-by: Robert Wilhelm <robert.wilhelm at gmx.net>
---
This function with HRESULT return value returned S_OK in all paths
but this one. It did not cause harm because all callers checked
return value with FAILED(hres).
---
 dlls/vbscript/interp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dlls/vbscript/interp.c b/dlls/vbscript/interp.c
index 342b7820eca..f050b23c1cd 100644
--- a/dlls/vbscript/interp.c
+++ b/dlls/vbscript/interp.c
@@ -146,7 +146,7 @@ static HRESULT lookup_identifier(exec_ctx_t *ctx, BSTR name, vbdisp_invoke_type_
             if(!wcsicmp(ctx->func->vars[i].name, name)) {
                 ref->type = REF_VAR;
                 ref->u.v = ctx->vars+i;
-                return TRUE;
+                return S_OK;
             }
         }

--
2.26.2





More information about the wine-devel mailing list