Send the pubsub subscription notification to the client. */
| 67 | |
| 68 | /* Send the pubsub subscription notification to the client. */ |
| 69 | void addReplyPubsubSubscribed(client *c, robj *channel) { |
| 70 | if (c->resp == 2) |
| 71 | addReply(c,shared.mbulkhdr[3]); |
| 72 | else |
| 73 | addReplyPushLen(c,3); |
| 74 | addReply(c,shared.subscribebulk); |
| 75 | addReplyBulk(c,channel); |
| 76 | addReplyLongLong(c,clientSubscriptionsCount(c)); |
| 77 | } |
| 78 | |
| 79 | /* Send the pubsub unsubscription notification to the client. |
| 80 | * Channel can be NULL: this is useful when the client sends a mass |
no test coverage detected