Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: af93d301ac12affa63d7e673198bef85f0dbd16a
      
https://github.com/WebKit/WebKit/commit/af93d301ac12affa63d7e673198bef85f0dbd16a
  Author: Rupin Mittal <[email protected]>
  Date:   2026-04-20 (Mon, 20 Apr 2026)

  Changed paths:
    M Source/WebKit/UIProcess/Cocoa/ProcessAssertionCocoa.mm

  Log Message:
  -----------
  StabilityTracer: NanoMail at RunningBoardServices: -[RBSAssertion dealloc]
https://bugs.webkit.org/show_bug.cgi?id=312804
rdar://174907623

Reviewed by Ben Nham.

[WKProcessAssertionBackgroundTaskManager _updateBackgroundTask] calls:

_backgroundTask = adoptNS([[RBSAssertion alloc] initWithExplanation:
@"WebKit UIProcess background task" target:target 
attributes:@[domainAttribute]]);

This line decrements the ref-count of the RBSAssertion that is currenly held by
_backgroundTask. According the crash log, it looks like the ref-count is 
dropping
to zero since [RBSAssertion dealloc] is called. The crash log says we crash
because "Dealloc called before invalidate for assertion <RBSAssertion...".

So we need to call invalidate on the the existing _backgroundTask before this
line decrements its ref-count. ProcessAssertionCocoa already has a function that
does this called _releaseBackgroundTask, so we call that.

This a speculative fix.

* Source/WebKit/UIProcess/Cocoa/ProcessAssertionCocoa.mm:
(-[WKProcessAssertionBackgroundTaskManager _updateBackgroundTask]):

Canonical link: https://commits.webkit.org/311649@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to