Skip to content
Permalink
Browse files
REGRESSION (251613@main): Missing exception check in JSFunction::put()
https://bugs.webkit.org/show_bug.cgi?id=241727

Unreviewed follow-up fix.

Adds exception check after reifyLazyPropertyIfNeeded() since it may throw.

* Source/JavaScriptCore/runtime/JSFunction.cpp:
(JSC::JSFunction::put):

Canonical link: https://commits.webkit.org/251664@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@295659 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
shvaikalesh committed Jun 18, 2022
1 parent 7b073e5 commit 627fc1e20a7fcc368199b2579894720c599a83e6
Showing 1 changed file with 1 addition and 0 deletions.
@@ -397,6 +397,7 @@ bool JSFunction::put(JSCell* cell, JSGlobalObject* globalObject, PropertyName pr
}

PropertyStatus propertyType = thisObject->reifyLazyPropertyIfNeeded(vm, globalObject, propertyName);
RETURN_IF_EXCEPTION(scope, false);
if (isLazy(propertyType))
slot.disableCaching();
RELEASE_AND_RETURN(scope, Base::put(thisObject, globalObject, propertyName, value, slot));

0 comments on commit 627fc1e

Please sign in to comment.