From 9cfefa09d67e1cde33bb652310e455715abccd05 Mon Sep 17 00:00:00 2001 From: Viktor Klang Date: Tue, 2 Mar 2010 00:20:23 +0100 Subject: [PATCH] Fix for link(..) --- akka-core/src/main/scala/actor/Actor.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/akka-core/src/main/scala/actor/Actor.scala b/akka-core/src/main/scala/actor/Actor.scala index a1eb6bd309..39a354a831 100644 --- a/akka-core/src/main/scala/actor/Actor.scala +++ b/akka-core/src/main/scala/actor/Actor.scala @@ -656,9 +656,9 @@ trait Actor extends TransactionManagement { * To be invoked from within the actor itself. */ protected[this] def link(actor: Actor) = { - getLinkedActors.add(actor) if (actor._supervisor.isDefined) throw new IllegalStateException( "Actor can only have one supervisor [" + actor + "], e.g. link(actor) fails") + getLinkedActors.add(actor) actor._supervisor = Some(this) Actor.log.debug("Linking actor [%s] to actor [%s]", actor, this) }