vbscript: Remove redundant NULL checks before SysFreeString().

Signed-off-by: Michael Stefaniuc <mstefani@winehq.org>
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Michael Stefaniuc 2019-11-08 21:07:09 +01:00 committed by Alexandre Julliard
parent a94c8d5b6b
commit 8b7e38c542
1 changed files with 3 additions and 3 deletions

View File

@ -2948,19 +2948,19 @@ static HRESULT Err_Raise(BuiltinDisp *This, VARIANT *args, unsigned args_cnt, VA
error = (code & ~0xffff) ? map_hres(code) : MAKE_VBSERROR(code);
if(source) {
if(ctx->ei.bstrSource) SysFreeString(ctx->ei.bstrSource);
SysFreeString(ctx->ei.bstrSource);
ctx->ei.bstrSource = source;
}
if(!ctx->ei.bstrSource)
ctx->ei.bstrSource = get_vbscript_string(VBS_RUNTIME_ERROR);
if(description) {
if(ctx->ei.bstrDescription) SysFreeString(ctx->ei.bstrDescription);
SysFreeString(ctx->ei.bstrDescription);
ctx->ei.bstrDescription = description;
}
if(!ctx->ei.bstrDescription)
ctx->ei.bstrDescription = get_vbscript_error_string(error);
if(helpfile) {
if(ctx->ei.bstrHelpFile) SysFreeString(ctx->ei.bstrHelpFile);
SysFreeString(ctx->ei.bstrHelpFile);
ctx->ei.bstrHelpFile = helpfile;
}
if(args_cnt >= 5)