Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: a39497ed4d9f8a3bfd65df6b07b50efe19eaac99
      
https://github.com/WebKit/WebKit/commit/a39497ed4d9f8a3bfd65df6b07b50efe19eaac99
  Author: Ahmad Saleem <[email protected]>
  Date:   2026-07-13 (Mon, 13 Jul 2026)

  Changed paths:
    A 
LayoutTests/inspector/debugger/probe-manager-remove-middle-action-expected.txt
    A LayoutTests/inspector/debugger/probe-manager-remove-middle-action.html
    M Source/WebInspectorUI/UserInterface/Controllers/DebuggerManager.js

  Log Message:
  -----------
  Web Inspector: probe manager drops probes when a breakpoint has multiple 
probe actions added or removed at once
https://bugs.webkit.org/show_bug.cgi?id=319274
rdar://182115866

Reviewed by Devin Rousso.

DebuggerManager.updateProbesForBreakpoint() has two loops that walk a
breakpoint's probe actions to reconcile them against the known probes.
Both used `break` where they should have used `continue`:

- The loop that creates newly-added probes bailed out entirely after
  creating the first new probe, so any additional new probes in the same
  pass were never created (and existing probes ordered after it never had
  their expressions refreshed).

- The loop that reaps probes no longer present stopped at the first probe
  that was still present, leaking any missing probe ordered after it in
  the known-identifier set (e.g. removing a middle or trailing probe left
  a stale WI.Probe in _probesByIdentifier and in the probe set).

These are normally masked because each single action mutation dispatches
its own ActionsDidChange event, so a pass usually sees only one changed
probe. The bug surfaces when a pass sees more than one change at once,
such as removing a non-first probe while others survive.

Changed both `break` statements to `continue`.

Test: inspector/debugger/probe-manager-remove-middle-action.html

* 
LayoutTests/inspector/debugger/probe-manager-remove-middle-action-expected.txt: 
Added.
* LayoutTests/inspector/debugger/probe-manager-remove-middle-action.html: Added.
* Source/WebInspectorUI/UserInterface/Controllers/DebuggerManager.js:
(WI.DebuggerManager.prototype.updateProbesForBreakpoint):

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



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

Reply via email to