diff --git a/poll/engine.go b/poll/engine.go index 239470d..1ab9802 100644 --- a/poll/engine.go +++ b/poll/engine.go @@ -162,7 +162,7 @@ func StartGetPeers(endpoint string, reportInstanceChan chan ReportInstance) { } } -func DeferRun(pollmessage PollMessage, runninginstances *[]RunningInstance, reportInstanceChan chan ReportInstance, reportPostChan chan ReportPost, pollMessageChan chan PollMessage) { +func DeferPollRun(pollmessage PollMessage, runninginstances *[]RunningInstance, reportInstanceChan chan ReportInstance, reportPostChan chan ReportPost, pollMessageChan chan PollMessage) { var min_id string for _, runninginstance := range *runninginstances { @@ -284,7 +284,7 @@ func main() { runninginstances[i].min_id = p.min_id } } - go DeferRun(p, &runninginstances, reportInstanceChan, reportPostChan, pollMessageChan) + go DeferPollRun(p, &runninginstances, reportInstanceChan, reportPostChan, pollMessageChan) case v := <-reportPostChan: // New Post go writePost(pool, v) case w := <-reportInstanceChan: // Start a new instance