• Bjorn Svensson's avatar
    Allow sending commands after sending an unsubscribe (#1036) · f2ce5980
    Bjorn Svensson authored
    * Add test of async commands after unsubscribe
    
    Verify that commands are handled after unsubscribing from a channel.
    A command is sent before the `unsubscribe` response is received,
    which currently triggers an assert in async.c:567:
    
    `redisProcessCallbacks: Assertion `(c->flags & REDIS_SUBSCRIBED || c->flags & REDIS_MONITORING)' failed.`
    
    * Handle async commands after an unsubscribe
    
    When unsubscribing from the last channel we move from the `subscribe`
    state to a normal state. These states uses different holders for the
    command callback information.
    By moving the callback info during the state change the callback order
    can be maintained.
    f2ce5980
async.c 29.1 KB