From d7bcdb0108fa5cfc84510d6b68627aaba138e3e2 Mon Sep 17 00:00:00 2001 From: shoopea Date: Wed, 31 Jul 2019 14:50:33 +0800 Subject: [PATCH] client revamping compilation fix --- client.go | 5 +++-- main.go | 1 + 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/client.go b/client.go index 55d58a9..6f67c09 100644 --- a/client.go +++ b/client.go @@ -23,8 +23,9 @@ func getLockedClient(id int64, createMissing bool) (*ChirpClient, bool) { return c, true } else { muxClients.RUnlock() - c := new(ChirpClient) - return c, false + //c := new(ChirpClient) + //return c, false + return nil, false } } diff --git a/main.go b/main.go index fdebccd..7d6421e 100644 --- a/main.go +++ b/main.go @@ -151,6 +151,7 @@ func main() { TGCmdQueue = make(chan TGCommand, TGCmdQueueSize) MQTGCmdQueue = make(chan TGCommand, MQTGCmdQueueSize) JobQueue = make(chan Job, JobQueueSize) + clients = make(map[int64]*ChirpClient) for w := 1; w <= MQGetMsgWorkers; w++ { go MQGetMsgWorker(w, MQCWMsgQueue)