Skip to content

Commit

Permalink
fixes bug in subnet
Browse files Browse the repository at this point in the history
  • Loading branch information
adam-hanna committed Oct 8, 2019
1 parent ae81699 commit 061e798
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion cmd/subnet/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,11 +77,17 @@ func setup() *cobra.Command {
}

// start the subnet
if err = snet.Start(); err != nil {
start := make(chan struct{})
if err = snet.Start(start); err != nil {
logger.Errorf("err starting subnet\n%v", err)
return err
}

select {
case <-start:
logger.Infof("subnet did start")
}

select {
case <-stop:
// note: I don't like '^C' showing up on the same line as the next logged line...
Expand Down

0 comments on commit 061e798

Please sign in to comment.