Skip to content
Snippets Groups Projects
Commit 9e85be8f authored by Rob Swindell's avatar Rob Swindell :speech_balloon:
Browse files

Setter needs to return true even when the scan pointer is NULL

(e.g. when run as a timed event) - this bug was introduced in the "Fix sub[] property setter" crash bug fix 2 commits ago.
This fixes the "TypeError: sub.code is undefined" error.
parent 48709dcb
No related branches found
No related tags found
1 merge request!463MRC mods by Codefenix (2024-10-20)
Pipeline #1116 passed
...@@ -315,7 +315,7 @@ static JSBool js_sub_set(JSContext *cx, JSObject *obj, jsid id, JSBool strict, j ...@@ -315,7 +315,7 @@ static JSBool js_sub_set(JSContext *cx, JSObject *obj, jsid id, JSBool strict, j
subscan_t* scan = p->subscan; subscan_t* scan = p->subscan;
if(scan == NULL) if(scan == NULL)
return JS_FALSE; return JS_TRUE;
JS_IdToValue(cx, id, &idval); JS_IdToValue(cx, id, &idval);
tiny = JSVAL_TO_INT(idval); tiny = JSVAL_TO_INT(idval);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment