[Webkit-unassigned] [Bug 235281] New: rx::angle::Result ProgramMtl::getSpecializedShader() leaks MTLFunctionConstantValues object due early return when an error occurs in ANGLE_TRY() macro
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Sun Jan 16 13:59:51 PST 2022
https://bugs.webkit.org/show_bug.cgi?id=235281
Bug ID: 235281
Summary: rx::angle::Result ProgramMtl::getSpecializedShader()
leaks MTLFunctionConstantValues object due early
return when an error occurs in ANGLE_TRY() macro
Product: WebKit
Version: Other
Hardware: Unspecified
OS: Unspecified
Status: NEW
Severity: Normal
Priority: P2
Component: ANGLE
Assignee: webkit-unassigned at lists.webkit.org
Reporter: ddkilzer at webkit.org
CC: dino at apple.com, kbr at google.com, kkinnunen at apple.com,
kpiddington at apple.com
Depends on: 220896
rx::angle::Result ProgramMtl::getSpecializedShader() leaks MTLFunctionConstantValues object due early return when an error occurs in ANGLE_TRY() macro.
The early return occurs before the object is autoreleased:
// Create Metal shader object
ANGLE_MTL_OBJC_SCOPE
{
ANGLE_TRY(CreateMslShader(context, translatedMslInfo->metalLibrary, SHADER_ENTRY_NAME,
funcConstants, &shaderVariant->metalShader));
[funcConstants ANGLE_MTL_AUTORELEASE];
}
Found by clang static analyzer.
Regressed with this commit:
Roll ANGLE to include upstreamed Metal backend
<https://bugs.webkit.org/show_bug.cgi?id=220896>
<rdar://problem/73539682>
<https://commits.webkit.org/r286603>
Referenced Bugs:
https://bugs.webkit.org/show_bug.cgi?id=220896
[Bug 220896] Roll ANGLE to include upstreamed Metal backend
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20220116/b4e0b47b/attachment.htm>
More information about the webkit-unassigned
mailing list