drone/drone — pull request #623 by daMupfel (2014-10-24 21:35:00+00:00)
Title: Fixesmissing live console output bug on rebuild

Hey there, I tried to fix the bug #448 with this commit. Since i looked today the first time at the codebase of this project, i am not 100% sure this is the correct solution.

The problem i saw was that when you force a rebuild, it gets stuck on:

```go
func (c *Channel) Subscribe() *Subscription {
s := NewSubscription(c)
c.subscribe <- s //<--- stuck here
return s
}
```

because the Channel was only closed, but not removed.

When you issue a new rebuild, it well return the old channel. But since the start loop is not working anymore, c.subscribe gets stuck because the value doesn't get pulled out of the queue.

So now i unregister the channel at the end of the build instead of just closing it.

Hope this helps

Best regards

David