From 8dce9b5489806dd15d163e697365da11999f69cd Mon Sep 17 00:00:00 2001 From: Adin Schmahmann Date: Wed, 24 Jul 2019 00:32:46 -0400 Subject: [PATCH] Fix hanging connects to bootstrapper Changed pubsub-interop bootstrapper from for-loop infinite loop to select infinite loop. --- pubsub/pubsub-interop.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pubsub/pubsub-interop.go b/pubsub/pubsub-interop.go index 161c3cd..334f05e 100644 --- a/pubsub/pubsub-interop.go +++ b/pubsub/pubsub-interop.go @@ -166,8 +166,7 @@ func main() { }) if bBootstrap { fmt.Println("Bootstrapper running.\nPubSub object instantiated using FloodSubRouter.\nCtrl+C to exit.") - for true { - } + select {} } else { // Now, wait for input from the user, and send that out! scan := bufio.NewScanner(os.Stdin)