jscript: Access the PROTREF with proper index instead of get_prop.
Signed-off-by: Gabriel Ivăncescu <gabrielopcode@gmail.com> Signed-off-by: Jacek Caban <jacek@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
5842ec60e2
commit
8b3afbe402
|
@ -109,8 +109,12 @@ static inline BOOL is_function_prop(dispex_prop_t *prop)
|
||||||
static DWORD get_flags(jsdisp_t *This, dispex_prop_t *prop)
|
static DWORD get_flags(jsdisp_t *This, dispex_prop_t *prop)
|
||||||
{
|
{
|
||||||
if(prop->type == PROP_PROTREF) {
|
if(prop->type == PROP_PROTREF) {
|
||||||
dispex_prop_t *parent = get_prop(This->prototype, prop->u.ref);
|
dispex_prop_t *parent = NULL;
|
||||||
if(!parent) {
|
|
||||||
|
if(prop->u.ref < This->prototype->prop_cnt)
|
||||||
|
parent = &This->prototype->props[prop->u.ref];
|
||||||
|
|
||||||
|
if(!parent || parent->type == PROP_DELETED) {
|
||||||
prop->type = PROP_DELETED;
|
prop->type = PROP_DELETED;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue