actors: Fix hive-actor-local? to check the hive id, not whether actor exists.
authorChristopher Allan Webber <cwebber@dustycloud.org>
Sat, 7 May 2016 17:23:53 +0000 (12:23 -0500)
committerChristopher Allan Webber <cwebber@dustycloud.org>
Sat, 7 May 2016 17:23:53 +0000 (12:23 -0500)
* 8sync/systems/actors.scm (hive-actor-local?): Update to check the hive id.

8sync/systems/actors.scm

index 8545e73a7751b86f6dcfdbbe4e6662ac2f201cf6..9ba3818b6ff1d6f6e34b0ff33ae65ad8f29ca619 100644 (file)
@@ -642,7 +642,7 @@ more compact following syntax:
         (process-remote-message))))
 
 (define-method (hive-actor-local? (hive <hive>) address)
-  (hash-ref (hive-actor-registry hive) address))
+  (equal? (hive-id hive) (address-hive-id address)))
 
 (define-method (hive-register-actor! (hive <hive>) (actor <actor>))
   (hash-set! (hive-actor-registry hive) (actor-id actor) actor))