oleaut32: Add missing return value checks (Coverity).

CID 1442938:  Error handling issues  (CHECKED_RETURN)

Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Alistair Leslie-Hughes 2019-03-03 22:05:18 +00:00 committed by Alexandre Julliard
parent 1866fd659a
commit 4a6f002d9a
1 changed files with 4 additions and 2 deletions

View File

@ -5138,7 +5138,9 @@ HRESULT WINAPI VarRound(LPVARIANT pVarIn, int deci, LPVARIANT pVarOut)
{
double dbl;
VarR8FromDec(&V_DECIMAL(pVarIn), &dbl);
hRet = VarR8FromDec(&V_DECIMAL(pVarIn), &dbl);
if (FAILED(hRet))
break;
if (dbl>0.0f)
dbl = floor(dbl*pow(10,deci)+0.5);
@ -5146,7 +5148,7 @@ HRESULT WINAPI VarRound(LPVARIANT pVarIn, int deci, LPVARIANT pVarOut)
dbl = ceil(dbl*pow(10,deci)-0.5);
V_VT(pVarOut)=VT_DECIMAL;
VarDecFromR8(dbl, &V_DECIMAL(pVarOut));
hRet = VarDecFromR8(dbl, &V_DECIMAL(pVarOut));
break;
}
/* cases we don't know yet */