redis/hiredis — pull request #236 by gsick (2014-04-14 11:20:34+00:00)
Title: In subscribed context, invalid command should not disconnect

In async subscribed context, when an invalide command is sent, the error "ERR only (P)SUBSCRIBE / (P)UNSUBSCRIBE / QUIT allowed in this context" close the connection instead of be passed to the callback.
It's a regression since the fix "Spontaneous error reply can always happen" https://github.com/redis/hiredis/commit/7ec4df9403e8c5be413693f5984edb8123cc72d5.
I didn't find a solution without compare the error string.

Cheers,