[PATCH] jscript: check the correct heap return condition (Coverity)
Marcus Meissner
marcus at jet.franken.de
Fri Mar 15 13:42:12 CDT 2013
CID 989100
Ciao, Marcus
---
dlls/jscript/jsregexp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/jscript/jsregexp.c b/dlls/jscript/jsregexp.c
index 61e9a95..3863142 100644
--- a/dlls/jscript/jsregexp.c
+++ b/dlls/jscript/jsregexp.c
@@ -609,7 +609,7 @@ HRESULT create_regexp(script_ctx_t *ctx, jsstr_t *src, DWORD flags, jsdisp_t **r
regexp->jsregexp = regexp_new(ctx, &ctx->tmp_heap, regexp->str->str,
jsstr_length(regexp->str), flags, FALSE);
- if(FAILED(hres)) {
+ if(!regexp->jsregexp) {
WARN("regexp_new failed\n");
jsdisp_release(®exp->dispex);
return E_FAIL;
--
1.7.10.4
More information about the wine-patches
mailing list