mirror of
https://github.com/redis/go-redis.git
synced 2025-07-28 06:42:00 +03:00
pub/sub: Clean up message parsing.
This commit is contained in:
@ -37,7 +37,6 @@ type Message struct {
|
||||
func (c *PubSubClient) consumeMessages(conn *Conn) {
|
||||
req := NewIfaceSliceReq()
|
||||
|
||||
for {
|
||||
for {
|
||||
msg := &Message{}
|
||||
|
||||
@ -73,11 +72,6 @@ func (c *PubSubClient) consumeMessages(conn *Conn) {
|
||||
msg.Err = fmt.Errorf("Unsupported message name: %q.", msgName)
|
||||
}
|
||||
c.ch <- msg
|
||||
|
||||
if conn.Rd.Buffered() <= 0 {
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user