From 0727fc1781e4ab9e367ce9945622be9f0a60e0d8 Mon Sep 17 00:00:00 2001 From: Amine Khaldi Date: Sun, 29 Mar 2015 13:54:08 +0000 Subject: [PATCH] [WSCRIPT_WINETEST] Sync with Wine Staging 1.7.37. CORE-9246 svn path=/trunk/; revision=66956 --- rostests/winetests/wscript/run.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/rostests/winetests/wscript/run.c b/rostests/winetests/wscript/run.c index d2e7cff00aa..5a16e3b545f 100644 --- a/rostests/winetests/wscript/run.c +++ b/rostests/winetests/wscript/run.c @@ -256,10 +256,10 @@ static HRESULT WINAPI Dispatch_Invoke(IDispatch *iface, DISPID dispIdMember, REF ok(pdp->cArgs == 0, "cArgs = %d\n", pdp->cArgs); ok(!pdp->cNamedArgs, "cNamedArgs = %d\n", pdp->cNamedArgs); V_VT(pVarResult) = VT_BSTR; - res = GetFullPathNameA(script_name, sizeof(fullPath)/sizeof(WCHAR), fullPath, &pos); - if(!res || res > sizeof(fullPath)/sizeof(WCHAR)) + res = GetFullPathNameA(script_name, sizeof(fullPath), fullPath, &pos); + if(!res || res > sizeof(fullPath)) return E_FAIL; - if(!(V_BSTR(pVarResult) = SysAllocString(a2bstr(pos)))) + if(!(V_BSTR(pVarResult) = a2bstr(pos))) return E_OUTOFMEMORY; break; } @@ -272,10 +272,10 @@ static HRESULT WINAPI Dispatch_Invoke(IDispatch *iface, DISPID dispIdMember, REF ok(pdp->cArgs == 0, "cArgs = %d\n", pdp->cArgs); ok(!pdp->cNamedArgs, "cNamedArgs = %d\n", pdp->cNamedArgs); V_VT(pVarResult) = VT_BSTR; - res = GetFullPathNameA(script_name, sizeof(fullPath)/sizeof(WCHAR), fullPath, NULL); - if(!res || res > sizeof(fullPath)/sizeof(WCHAR)) + res = GetFullPathNameA(script_name, sizeof(fullPath), fullPath, NULL); + if(!res || res > sizeof(fullPath)) return E_FAIL; - if(!(V_BSTR(pVarResult) = SysAllocString(a2bstr(fullPath)))) + if(!(V_BSTR(pVarResult) = a2bstr(fullPath))) return E_OUTOFMEMORY; break; }