Commit 1d2ac5d8 authored by Daniel Lehman's avatar Daniel Lehman Committed by Alexandre Julliard

oleaut32: Extend value range before getting absolute value in VarBstrFromI4.

parent 7198499d
......@@ -4556,7 +4556,7 @@ static void test_VarBstrFromI4(void)
ok(hres == S_OK, "got hres 0x%08x\n", hres);
if (bstr)
{
todo_wine ok(memcmp(bstr, int_min, sizeof(int_min)) == 0, "string different\n");
ok(memcmp(bstr, int_min, sizeof(int_min)) == 0, "string different\n");
SysFreeString(bstr);
}
......
......@@ -6453,7 +6453,7 @@ HRESULT WINAPI VarBstrFromI4(LONG lIn, LCID lcid, ULONG dwFlags, BSTR* pbstrOut)
if (lIn < 0)
{
ul64 = (ULONG)-lIn;
ul64 = -(LONG64)lIn;
dwFlags |= VAR_NEGATIVE;
}
return VARIANT_BstrFromUInt(ul64, lcid, dwFlags, pbstrOut);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment