[prev in list] [next in list] [prev in thread] [next in thread]
List: wine-devel
Subject: [PATCH 06/10] jscript: Directly return error code instead of using throw_regexp_error.
From: Jacek Caban <jacek () codeweavers ! com>
Date: 2020-01-31 16:23:10
Message-ID: aa4ee3f3-7ccb-0c84-8e44-8bb95476d9fa () codeweavers ! com
[Download RAW message or body]
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
---
dlls/jscript/error.c | 5 -----
dlls/jscript/jscript.h | 1 -
dlls/jscript/jsregexp.c | 2 +-
3 files changed, 1 insertion(+), 7 deletions(-)
["0006-jscript-Directly-return-error-code-instead-of-using-th.txt" (text/x-patch)]
diff --git a/dlls/jscript/error.c b/dlls/jscript/error.c
index 8a49c973dc..084e8ce953 100644
--- a/dlls/jscript/error.c
+++ b/dlls/jscript/error.c
@@ -435,11 +435,6 @@ static HRESULT throw_error(script_ctx_t *ctx, HRESULT error, const WCHAR *str, j
return error;
}
-HRESULT throw_regexp_error(script_ctx_t *ctx, HRESULT error, const WCHAR *str)
-{
- return throw_error(ctx, error, str, ctx->regexp_error_constr);
-}
-
HRESULT throw_syntax_error(script_ctx_t *ctx, HRESULT error, const WCHAR *str)
{
return throw_error(ctx, error, str, ctx->syntax_error_constr);
diff --git a/dlls/jscript/jscript.h b/dlls/jscript/jscript.h
index 678c02acf6..cf5870f8a1 100644
--- a/dlls/jscript/jscript.h
+++ b/dlls/jscript/jscript.h
@@ -312,7 +312,6 @@ HRESULT Function_get_value(script_ctx_t*,jsdisp_t*,jsval_t*) DECLSPEC_HIDDEN;
struct _function_code_t *Function_get_code(jsdisp_t*) DECLSPEC_HIDDEN;
#define DEFAULT_FUNCTION_VALUE {NULL, Function_value,0, Function_get_value}
-HRESULT throw_regexp_error(script_ctx_t*,HRESULT,const WCHAR*) DECLSPEC_HIDDEN;
HRESULT throw_syntax_error(script_ctx_t*,HRESULT,const WCHAR*) DECLSPEC_HIDDEN;
HRESULT throw_type_error(script_ctx_t*,HRESULT,const WCHAR*) DECLSPEC_HIDDEN;
HRESULT throw_uri_error(script_ctx_t*,HRESULT,const WCHAR*) DECLSPEC_HIDDEN;
diff --git a/dlls/jscript/jsregexp.c b/dlls/jscript/jsregexp.c
index 9a6ad0e37e..fc9255e1a1 100644
--- a/dlls/jscript/jsregexp.c
+++ b/dlls/jscript/jsregexp.c
@@ -935,7 +935,7 @@ static HRESULT RegExpConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags
if(is_class(jsdisp, JSCLASS_REGEXP)) {
if(argc > 1 && !is_undefined(argv[1])) {
jsdisp_release(jsdisp);
- return throw_regexp_error(ctx, JS_E_REGEXP_SYNTAX, NULL);
+ return JS_E_REGEXP_SYNTAX;
}
if(r)
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic