Skip to content

Commit

Permalink
ActorCell.DeathWatch InvalidOperationException during AddressTerminated
Browse files Browse the repository at this point in the history
  • Loading branch information
rogeralsing authored and Horusiath committed Jul 3, 2015
1 parent 2025d0d commit 016fcc7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/core/Akka/Actor/ActorCell.DeathWatch.cs
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,8 @@ protected void AddressTerminated(Address address)
// cleanup watchedBy since we know they are dead
MaintainAddressTerminatedSubscription(() =>
{
foreach (var a in _state.GetWatchedBy().Where(a => a.Path.Address == address))

foreach (var a in _state.GetWatchedBy().Where(a => a.Path.Address == address).ToList())
{
//_watchedBy.Remove(a);
_state = _state.RemoveWatchedBy(a);
Expand Down

0 comments on commit 016fcc7

Please sign in to comment.